I am trying to code a macro that would resize the table to fit the content. Right now I have this code and I keep getting the error that my range is invalid. What am I doing wrong? Thanks
Workbooks("A-50 -Suivi des risques V.0.xlsm").Sheets("Feuil1").Range("A1").Select
Range(Selection, Selection.End(xlDown)).Select
Range(Selection, Selection.End(xlToRight)).Select
Dim SelRange As Range
Set SelRange = Selection
Workbooks("A-50 -Suivi des risques V.0.xlsm").Sheets("Feuil1").ListObjects("Tableau12").Resize Range(SelRange)