Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
lonnied
 
Posts: n/a
Default Can a macro be made to work based on a formula?

Is it possible to have a macro run based on the answer to a question? If the
answer to a certain question is yes then the macro would run.
  #2   Report Post  
Myrna Larson
 
Posts: n/a
Default

A formula in a worksheet cell can call a function written in VBA. But that
function can only return a result to the cell containing the formula, just
like the built-in functions like SUM and AVERAGE do. The code can't change
other cells, do formatting, etc.


On Tue, 25 Jan 2005 18:59:04 -0800, "lonnied"
wrote:

Is it possible to have a macro run based on the answer to a question? If the
answer to a certain question is yes then the macro would run.


  #3   Report Post  
Myrna Larson
 
Posts: n/a
Default

Addendum: a Worksheet event macro like Worksheet_Calculate or Worksheet_Change
can monitor the results in a given cell and run more code if the value meets
your criteria.

On Tue, 25 Jan 2005 21:57:45 -0600, Myrna Larson
wrote:

A formula in a worksheet cell can call a function written in VBA. But that
function can only return a result to the cell containing the formula, just
like the built-in functions like SUM and AVERAGE do. The code can't change
other cells, do formatting, etc.


On Tue, 25 Jan 2005 18:59:04 -0800, "lonnied"
wrote:

Is it possible to have a macro run based on the answer to a question? If the
answer to a certain question is yes then the macro would run.


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
Can a macro be made to work based on a formula? lonnied Excel Discussion (Misc queries) 0 January 26th 05 02:59 AM
Excel 97 - Adding Every 8th Row - Formula should work, but doesn't Damaeus Excel Worksheet Functions 12 January 23rd 05 04:52 PM
Formula to return cell contents based on multiple conditions Bill Excel Worksheet Functions 3 January 19th 05 09:59 AM
Help with macro formula and variable Huge project Excel Worksheet Functions 0 December 28th 04 01:27 AM
Macro Formula revision? Mark Excel Worksheet Functions 1 November 28th 04 01:43 AM


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