i'm using the following code which is assigned to a button to create a new row and copy the contents from the row above.
each row has a special # (for example in column A each row is numbered SU-1, SU-2, SU-3, etc..). I'm looking for the button to continue the numbering system, so for example the last row may be SU-9, when a new row is created (by click of the button) i want it to automatically be numbered SU-10 then SU-11 and so on.
Also instead of coping the entire row, i would like certain cells to become blank when the button is clicked. (cells C, D, F, G, H). so for instance the last row will have information in cells CDFGH (the other cells have formulas), when a new row in created I would like cells CDFGH to be blank and only the other cells to be copied.
any help would be much appreciated!
Sub BuyOuts_Click()
r = Columns(1).Find("DM", LookIn:=xlValues, LookAt:=xlWhole).Row
Rows(r - 1).Copy
Rows(r).Insert
Application.CutCopyMode = False
End Sub
Bookmarks