Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Using a macro to set a range name in EXCEL

I cannot figure out how to define a range name with a
macro. The range is variable
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default Using a macro to set a range name in EXCEL

Range(Cells(1,1),Cells(1,1).End(xldown)).Name = "RangeName"

--
Regards,
Tom Ogilvy


Eric Tepen wrote in message
...
I cannot figure out how to define a range name with a
macro. The range is variable



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 550
Default Using a macro to set a range name in EXCEL

Eric,

A simple way to name a range would be:

range("A1:C5").Name = "TestRange"

The range is variable

In what way???
Rows?
Columns?

There are a lot of variations on the above.
Post back with more info and someone will be sure to help you out.

John

"Eric Tepen" wrote in message
...
I cannot figure out how to define a range name with a
macro. The range is variable



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
Need help writing Excel macro when range changes AT Excel Worksheet Functions 1 December 13th 07 03:09 AM
macro to copy from excel range to word doc mopgcw Excel Discussion (Misc queries) 1 August 20th 07 07:54 PM
Help with Dynamically changing Range in Excel Macro runsrealfast Excel Discussion (Misc queries) 4 July 16th 07 10:44 PM
How do I set up a formula with a changing range in an excel macro cinvic Excel Discussion (Misc queries) 2 April 4th 06 10:39 PM
Macro to copy range from Excel files in folder nc Excel Discussion (Misc queries) 1 June 15th 05 11:11 AM


All times are GMT +1. The time now is 11:57 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"