Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Macro Recording

Can anyone explain why when I record a macro which names a range, the macro
records

ActiveWorkbook.Names.Add Name:="New NamedRange", RefersToR1C1:= _
"='Cricket Shirts'!R1C1:R26C5"

I am not aware of any setting that tells it to record in RowColumn notation,
I certainly do not have that option ticked in Options | General.

Can anyone explain why the address of the range is not in normal alpha
numeric notations.

PWS


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Macro Recording

Paul

Its just the way Excel works. R1C1 is the active cell and
Excel refers to it in RC notation. Heres one I recorded

Sub Macro1()
' Macro1 Macro
' Macro recorded 01/05/2004 by Peter Atherton

Range("B16:B20").Select
ActiveWorkbook.Names.Add Name:="Rng", _
RefersToR1C1:="=Sheet4!R16C2:R20C2"
End Sub

Note when the range is selected first the AlphaNumeric
notation is used. Normally you would not record a one off
event like createing a range name but you might want to
refer to it later. The sub below selects the name just
created.

Sub Selct()
[rng].Select
End Sub

Regards
Peter
-----Original Message-----
Can anyone explain why when I record a macro which names

a range, the macro
records

ActiveWorkbook.Names.Add Name:="New NamedRange",

RefersToR1C1:= _
"='Cricket Shirts'!R1C1:R26C5"

I am not aware of any setting that tells it to record in

RowColumn notation,
I certainly do not have that option ticked in Options |

General.

Can anyone explain why the address of the range is not in

normal alpha
numeric notations.

PWS


.

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
Recording a macro Sharon New Users to Excel 1 March 21st 07 08:23 PM
My excel macro recorder no longer shows up when recording macro jack Excel Discussion (Misc queries) 1 February 5th 07 09:31 PM
My excel macro recorder no longer shows up when recording macro jack Excel Discussion (Misc queries) 3 February 5th 07 08:22 PM
Add value when recording a macro LizW Charts and Charting in Excel 1 September 16th 05 09:40 PM
Macro recording box Anatoly Excel Programming 2 December 25th 03 04:00 PM


All times are GMT +1. The time now is 11:29 PM.

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"