Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,101
Default Help with Looping I think

I have a range of cells A1:A10. I have named the range "Data". How can I
specify to run a procedure for every cell within that range without
specifying cell references? In case a cell is added or deleted to the range
name, I still only want the procedure to dun for the cells within that range
name. Make sense?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default Help with Looping I think

Give something like this a try...

Dim rng as range

for each rng in Range("MyRange")
msgbox rng.value
next rng
--
HTH...

Jim Thomlinson


"Mike" wrote:

I have a range of cells A1:A10. I have named the range "Data". How can I
specify to run a procedure for every cell within that range without
specifying cell references? In case a cell is added or deleted to the range
name, I still only want the procedure to dun for the cells within that range
name. Make sense?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,101
Default Help with Looping I think

thanks

"Jim Thomlinson" wrote:

Give something like this a try...

Dim rng as range

for each rng in Range("MyRange")
msgbox rng.value
next rng
--
HTH...

Jim Thomlinson


"Mike" wrote:

I have a range of cells A1:A10. I have named the range "Data". How can I
specify to run a procedure for every cell within that range without
specifying cell references? In case a cell is added or deleted to the range
name, I still only want the procedure to dun for the cells within that range
name. Make sense?

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
Looping Maggie[_6_] Excel Discussion (Misc queries) 6 October 2nd 08 09:14 PM
Looping David T Excel Discussion (Misc queries) 2 August 30th 06 10:51 PM
Looping Embalmer Excel Programming 1 January 8th 06 11:51 PM
Looping Steve Excel Programming 2 September 9th 05 12:45 PM
Looping Andrew Clark[_2_] Excel Programming 1 December 20th 03 05:01 PM


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

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

About Us

"It's about Microsoft Excel"