Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 108
Default Converting code to R1C1 format

Hi-

is it possible to write this line of code in R1C1 format
instead of hardcoding the range? I want to be able to use
it multiple times without updating the cell reference
every time. Thanks!

Selection.AutoFill Destination:=Range("E19:AN19"),
Type:=xlFillDefault


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default Converting code to R1C1 format

How about:

With ActiveCell
.AutoFill Destination:=.Resize(1, 36), Type:=xlFillDefault
end with

But if you wanted to start in column E no matter where you were in that row:

With Cells(ActiveCell.Row, "E")
.AutoFill Destination:=.Resize(1, 36), Type:=xlFillDefault
End With



Paul wrote:

Hi-

is it possible to write this line of code in R1C1 format
instead of hardcoding the range? I want to be able to use
it multiple times without updating the cell reference
every time. Thanks!

Selection.AutoFill Destination:=Range("E19:AN19"),
Type:=xlFillDefault


--

Dave Peterson

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Question on this conversion code switching between r1c1 to A1 format tia sal2 temp Excel Worksheet Functions 1 September 16th 07 06:54 AM
Question on this conversion code switching between r1c1 to A1 format tia sal2 temp Excel Discussion (Misc queries) 2 September 14th 07 08:58 PM
Question on this conversion code switching between r1c1 to A1 format tia sal2 temp Excel Worksheet Functions 2 September 14th 07 08:58 PM
help on Converting R1C1 to A1 and A1 to R1C1..tia sa2 temp Excel Discussion (Misc queries) 3 September 13th 07 08:31 AM
help on Converting R1C1 to A1 and A1 to R1C1..tia sa2 temp Excel Worksheet Functions 3 September 13th 07 08:31 AM


All times are GMT +1. The time now is 06:39 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"