B
Basta1980
Hi,
I try to wright a command which autofills a range adjacent to information in
the cells left. So if Range A1:A300 contains data and I have a formule in cel
B1 I normally double click the fill-handle to copy (or autofill) the formula
down to cel B300 (which is adjacent to cel A300). The below statement helps
me manage to automatically autofill the range (B1:B300). My problem is that
range A can be variable, so this time it's up to cel A300, the following time
it's up to cel A500. How should i adjust the statement?!
Sub test()
'
' test Macro
' Macro recorded 19-03-2008 by dresses
'
'
Range("B1").Select
Selection.AutoFill Destination:=Range("B1:B316")
Range("B1:B316").Select
End Sub
I try to wright a command which autofills a range adjacent to information in
the cells left. So if Range A1:A300 contains data and I have a formule in cel
B1 I normally double click the fill-handle to copy (or autofill) the formula
down to cel B300 (which is adjacent to cel A300). The below statement helps
me manage to automatically autofill the range (B1:B300). My problem is that
range A can be variable, so this time it's up to cel A300, the following time
it's up to cel A500. How should i adjust the statement?!
Sub test()
'
' test Macro
' Macro recorded 19-03-2008 by dresses
'
'
Range("B1").Select
Selection.AutoFill Destination:=Range("B1:B316")
Range("B1:B316").Select
End Sub