I know this is for "ACAD" but I realize a lot of people on here do program with Excel as well; me being one of them
So I was wondering if anyone could answer this question for me?
I have macros, that read from very specific rows however one thing I never looked in to (and now need to) was; if the user inserts a new row, how can my macros dynamically adjust to the insert?
Here is a small example of something I did
Dim i As Integer
On Error Resume Next
'Check for unpaid bills
With Sheets(2).Select
For i = 6 To 22
If Range("N" & i).Value > 0 Then
If MsgBox("Do you want to overwrite last week's bills?", vbQuestion + vbYesNo, "Checking Accounts") = vbYes & vbCrLf _
Then GoTo Continue Else
Range("L6").Select
Exit Sub
End If
Next i
End With
Now if the user inserts a row, my range would now need to be 6 to 23.
Is there a way to do this in VBA?
Thank you
Mark