Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I have a function like this..
=IF(expr 0 , expr , " ") Now if my expr is again a big formula.. then is there any way of avoiding repeating it as the second argument.. ie any temporary variable for storage is available? like this... =IF ((a=long_expr) 0 , a , ""); |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
If it is just one cell, then use a cell somewhere else to store the
value, eg put your expression in X1 then your formula can be: =IF(X10,X1,"") If you are doing this on a column of cells, then just copy the expression down the X column (often referred to as a helper column), then copy your formula down. Hope this helps. Pete On Apr 16, 12:40 pm, Chinni Krishna Reddy <Chinni Krishna wrote: I have a function like this.. =IF(expr 0 , expr , " ") Now if my expr is again a big formula.. then is there any way of avoiding repeating it as the second argument.. ie any temporary variable for storage is available? like this... =IF ((a=long_expr) 0 , a , ""); |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Unfortunately, you will have to have the formula stated twice, either within
the IF() function or somewhere else in the sheet. However, if you are testing for an error, Excel 2007 has a new IfError() function that allows you state your formula but once: =iferror(long formula, value if formula errors) If the formula works, IFERROR() gives the formula's results. If it errors, IFERROR() returns the "value of formula errors" "Chinni Krishna Reddy" wrote: I have a function like this.. =IF(expr 0 , expr , " ") Now if my expr is again a big formula.. then is there any way of avoiding repeating it as the second argument.. ie any temporary variable for storage is available? like this... =IF ((a=long_expr) 0 , a , ""); |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You might also look at Laurent Longre's morefunc.xll add-in. The SETV and
GETV functions appear to be applicable to what you want to do. http://xcell05.free.fr/ Or maybe you could just use =MAX(expr, 0) and use a custom number format like 0;-0;; to suppress displaying the 0 if you do not want it displayed? The cell will still have a value of 0 - so this may affect your dependent formulas. "Chinni Krishna Reddy" wrote: I have a function like this.. =IF(expr 0 , expr , " ") Now if my expr is again a big formula.. then is there any way of avoiding repeating it as the second argument.. ie any temporary variable for storage is available? like this... =IF ((a=long_expr) 0 , a , ""); |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You might try using 2 cells.
Say A1 is =expr And, in the result cell: =IF(A10,A1,"") -- HTH, RD --------------------------------------------------------------------------- Please keep all correspondence within the NewsGroup, so all may benefit ! --------------------------------------------------------------------------- "Chinni Krishna Reddy" <Chinni Krishna wrote in message ... I have a function like this.. =IF(expr 0 , expr , " ") Now if my expr is again a big formula.. then is there any way of avoiding repeating it as the second argument.. ie any temporary variable for storage is available? like this... =IF ((a=long_expr) 0 , a , ""); |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Data Storage | Excel Discussion (Misc queries) | |||
CHANGE STORAGE DRIVES | Excel Discussion (Misc queries) | |||
horseracing results database storage | Setting up and Configuration of Excel | |||
newbie needs help with data storage | Excel Discussion (Misc queries) | |||
data storage from one worksheet to another | Excel Worksheet Functions |