Hi guys!
Alright... I am running around trying to find a way to work this, and I'm not very good with macros yet.
I have a sheet that summarizes about 15 other sheets, but I need to make a button that will allow the user to create a row to enter in new data in one of the other 15 sheets. I have two issues I'm trying to solve:
1) create a new row on the row above the last row of the table (the last row will be used to sum up the numbers above it
2) When the user creates a new row in the one sheet, to make it also create a new row in the summary sheet.
Below is what I got so far for the macro button, but I don't know enough about macros to get it to work for what I need it for. If anyone could help I would greatly appreciate it.
Private Sub CommandButton1_Click()
Dim the_sheet As Worksheet
Dim table_list_object As ListObject
Dim table_object_row As ListRow
Set the_sheet = Sheets("General Conditions")
Set table_list_object = the_sheet.ListObjects(1)
Set table_object_row = table_list_object.ListRows.Add
table_object_row.Range(-2, 1).Value = "New Item"
last_row_with_data = the_sheet.Range("A" & Rows.Count).End(xlUp).Row
the_sheet.Range("B" & last_row_with_data) = "Title Name"
the_sheet.Range("C" & last_row_with_data) = "Ref Number"
End Sub
Bookmarks