Hello!!
I have a listobject named "Tableau_Suivi". How can I do with VBA to include the last rows in the table? (The number of rows to be added may vary)
Currently, I go through an "unlist" step and then I select the whole thing to rename it "Tableau_Suivi", but I think there is a more "pro" way to do it?
in advance, thank you for your help
I have a listobject named "Tableau_Suivi". How can I do with VBA to include the last rows in the table? (The number of rows to be added may vary)
Rich (BB code):
Sub essai2()
Dim table1 As ListObject
Dim rg As Range
Dim CL As Workbook
Set CL = ThisWorkbook
Set table1 = ThisWorkbook.Worksheets("SUIVI").ListObjects("Tableau_Suivi")
table1.Unlist
Set rg = CL.Worksheets("SUIVI").Cells(2, 1).CurrentRegion
ActiveSheet.ListObjects.Add(xlSrcRange, rg, , xlYes).Name = "Tableau_Suivi"
End Sub
Currently, I go through an "unlist" step and then I select the whole thing to rename it "Tableau_Suivi", but I think there is a more "pro" way to do it?
in advance, thank you for your help