HI, i want to autofill my formula to the last column. here is my code
I have suceed count the last column by variable "LastColumn", but during the autofill, it failed. so i want to autofill start from column B to the column Lastcolumn.
Please help whats wrong with my code!
Code:
Dim LastColumn As Long
LastColumn = Cells(5, Columns.Count).End(xlToLeft).Column
Selection.AutoFill Destination:=Range("B1:" & LastColumn & "1"), Type:=xlFillDefault
I have suceed count the last column by variable "LastColumn", but during the autofill, it failed. so i want to autofill start from column B to the column Lastcolumn.
Please help whats wrong with my code!