Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Set formula as variable w/o "=" sign
I have the following formula in my cell
=AVERAGE(OFFSET(C15,-3,0,-12,1)) I want to set a variable as the formula, such as MyFormula = ActiveCell.Formula How can I get rid of the "=" sign at the beginning? I basically need to add a condition to the beginning and end of the formula and don't want the "=" inserted in the middle. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Set formula as variable w/o "=" sign
MyFormula = Mid$(ActiveCell.Formula, 2)
- Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions Peltier Technical Services, Inc. - http://PeltierTech.com _______ "StephanieH" wrote in message ... I have the following formula in my cell =AVERAGE(OFFSET(C15,-3,0,-12,1)) I want to set a variable as the formula, such as MyFormula = ActiveCell.Formula How can I get rid of the "=" sign at the beginning? I basically need to add a condition to the beginning and end of the formula and don't want the "=" inserted in the middle. |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Set formula as variable w/o "=" sign
Stephanie,
MyFormula = Mid(ActiveCell.Formula, 2, Len(ActiveCell.Formula)) HTH, Bernie MS Excel MVP "StephanieH" wrote in message ... I have the following formula in my cell =AVERAGE(OFFSET(C15,-3,0,-12,1)) I want to set a variable as the formula, such as MyFormula = ActiveCell.Formula How can I get rid of the "=" sign at the beginning? I basically need to add a condition to the beginning and end of the formula and don't want the "=" inserted in the middle. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How to handle a minus sign "-" as text not as part of a formula? | Excel Discussion (Misc queries) | |||
What is purpose of + sign in formula "=+Q290*10" | Excel Discussion (Misc queries) | |||
How to "sign" macro with "digital certificate"? | New Users to Excel | |||
How do display a "+" or "-" sign when hiding columns? | Setting up and Configuration of Excel | |||
use variable in Workbooks("book1").Worksheets("sheet1").Range("a1" | Excel Programming |