Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / March 2008

Tip: Looking for answers? Try searching our database.

variable row on fill?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
John - 19 Mar 2008 14:25 GMT
Range("A3").Select
   Selection.End(xlDown).Select
   Row = ActiveCell.Row
   
   Range("M4:W4").Select
   Selection.AutoFill Destination:=Range("m4:E" & Row)
   Range("m4:E" & Row).Select

The auto fill line doesn't work any thoughts are appreciated.  thanks
Tom Hutchins - 19 Mar 2008 14:51 GMT
Please see Bob Phillips' response to your identical post from yesterday. If
you check the VBA help on AutoFill, it says the destination range must
include the source range. In other words, you have to autofill to the same
column(s) and include the source range, just as if you were autofilling the
range manually. My suggestion is that you first copy or move the source range
to e4:m4, then autofill down from there. However, your current source range
(M4:W4) includes 11 columns, but your destination range only includes 9
columns.

Hope this helps,

Hutch

> Range("A3").Select
>     Selection.End(xlDown).Select
[quoted text clipped - 5 lines]
>
> The auto fill line doesn't work any thoughts are appreciated.  thanks
John - 19 Mar 2008 17:00 GMT
thanks tom, my internet timed out yesterday and I didn't see the post.  thanks

> Please see Bob Phillips' response to your identical post from yesterday. If
> you check the VBA help on AutoFill, it says the destination range must
[quoted text clipped - 18 lines]
> >
> > The auto fill line doesn't work any thoughts are appreciated.  thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.