Home |
Search |
Today's Posts |
|
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Determine if Row/Column was Added/Deleted
It would help to see the code you have.
"Paige" wrote: I have code that activates whenever a row/column has been added/deleted, and records the affected row #/column # on a 'change history' tab. How do I adjust the code tho so that it will record an add versus a delete. For example, if it records that $N:$N was added, can I have it put a 'D' after that ($N:$N D) so that I know the column was deleted (versus added), or an 'A' if added? Have tried messing around with used range count, but so far haven't been able to come up with anything. Any help would be appreciated. Thanks! |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Determine if Row/Column was Added/Deleted
Hi, JLGWhiz; thanks for responding. Here is the code:
If Target.Address = Target.EntireRow.Address Or Target.Address = Target.EntireColumn.Address Then Worksheets("History").Range("A65536").End(xlUp).Of fset(0, 1).Select If Target.Address = Target.EntireRow.Address Then ActiveCell.Value = Target.EntireRow.Address End If If Target.Address = Target.EntireColumn.Address Then ActiveCell.Value = Target.EntireColumn.Address End If End If "JLGWhiz" wrote: It would help to see the code you have. "Paige" wrote: I have code that activates whenever a row/column has been added/deleted, and records the affected row #/column # on a 'change history' tab. How do I adjust the code tho so that it will record an add versus a delete. For example, if it records that $N:$N was added, can I have it put a 'D' after that ($N:$N D) so that I know the column was deleted (versus added), or an 'A' if added? Have tried messing around with used range count, but so far haven't been able to come up with anything. Any help would be appreciated. Thanks! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Keep a column of comments "with" pivot table as pivot tables datachanges, causing rows to be added and deleted. | Excel Discussion (Misc queries) | |||
compare sheets for added or deleted rows | Excel Programming | |||
compare and find added or deleted rows | Excel Programming | |||
how to detect added or deleted rows in compare | Excel Programming | |||
How do I keep a formula from changing if a row is added or deleted | Excel Discussion (Misc queries) |