View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Niek Otten
 
Posts: n/a
Default HOW DO YOU INSERT A MACRO INTO A FORMULA

You cannot execute a macro from a formula.
You can use conditional formatting for the "target" cell or you can write a
worksheet_change event macro. The first is by far the easiest.

--
Kind regards,

Niek Otten

"blopreste3180" wrote in message
...
I am trying to insert a macro based on a "If" formula that will highlight a
specific cell or range of cells in a worksheet to a particular color. For
example, if todays date is 30 days or less from a target date, then I want
a
name on a particular sheet to turn red to let me know to do something. Any
help is appreciated.