Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Formula defines range or runs macro

We are trying to find a way to change a range name area based on the data in
a cell. For instance if cell A5=10 it will change a defined range name
"motor" to specific cells B10:C15 on another sheet. If cell A5 is then
changed to 20 the range name will change to B10: C25 etc.

Another option we could use is if cell A5=10 run a specific macro. We have
tried to write a conditional statement that will fire the macro when a
condition is met but that didn't work. Does anyone have any ideas on how to
make this work? Thanks in advance for any assistance you can provide.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 493
Default Formula defines range or runs macro

one way:

Choose Insert/Name/Define

enter motor in the Name in workbook: field, and in the Refers to:
field enter:

=OFFSET('Sheet2'!$B$10,0,0,'Sheet1'!$A$5-4,2)

Adjust your sheet names to suit...

In article ,
"Mike" wrote:

We are trying to find a way to change a range name area based on the data in
a cell. For instance if cell A5=10 it will change a defined range name
"motor" to specific cells B10:C15 on another sheet. If cell A5 is then
changed to 20 the range name will change to B10: C25 etc.

Another option we could use is if cell A5=10 run a specific macro. We have
tried to write a conditional statement that will fire the macro when a
condition is met but that didn't work. Does anyone have any ideas on how to
make this work? Thanks in advance for any assistance you can provide.


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
VBA macro runs fine, but freezes if I try to do ANYTHING else whileit runs Rruffpaw Setting up and Configuration of Excel 1 September 17th 11 01:25 PM
I need a macro that runs other macros until P5=28 Jeff Excel Discussion (Misc queries) 6 May 7th 08 11:44 PM
user defines macro to run bwilk77 Excel Discussion (Misc queries) 4 March 23rd 07 09:26 PM
One macro runs then it auto runs another macro PG Excel Discussion (Misc queries) 2 September 1st 06 09:30 PM
Which Macro Runs...? Bill Martin Excel Discussion (Misc queries) 7 September 29th 05 12:42 PM


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