View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
DireWolf DireWolf is offline
external usenet poster
 
Posts: 14
Default Fill column macro that stops

I have a speadsheet that has data in column A

I want to have a macro that takes the header from B1 and fills the
rest of column B until the end of data in column A

I currently use this code but it fills too far and I get an error when
I then try and import the file into another application.

Dim X As Range

Set X = ActiveSheet.[B1]
X.AutoFill Destination:=X.Resize(X.End(xlDown).Row, 1)
Range("B1:B10").Select

So in persudo code I suppose its like this

while A != empty
fill B
else
end