I have the code below behind a command button on a worksheet and I have tried adding the bit highlighted in red to the beginning but when I try running the code now I get a 'compile error' "For control variable already in use" and when I debug it highlights the text "For i = 4 To lrow" (highlighted in red). Can anyone help with what I need to change to make this work? Please let me know if it needs further clarification of what it is supposed to be doing.
I also want to add some code to the macro where I have highlighted in green further down. At this point in the macro I want some code that deletes rows where the value in column P is the same as column BA. Any help here would be greatly appreciated too.
![]()
Please Login or Register to view this content.
Bookmarks