IF Function - Specific currency format
Thank you (again) Harlan. The volatile suggestion is a good one.
--
Gary''s Student - gsnu200715
"Harlan Grove" wrote:
Colin wrote...
....
If I understand this correctly, I paste your UDF (What does this
mean?) . . .
UDF is the acronym for user-defined function.
. . . code into the VBA code window of the spreadsheet that holds
the information I want to use this code with. . . .
....
I have not put the code into its own module or anything.
What am I doing wrong?
....
You need to put udfs into so-called general VBA modules, i. e., you
need to put the code into its own module.
Switch to the Visual Basic Editor (VBE) by pressing [Alt]+[F11], then
run the VBE menu command Insert Module to create a new, blank
general module, and paste the udf code into it.
Since Excel provides many different Euro number formats, the key seems
to be the presence of the Euro symbol ‚¬ somewhere in the cell's
display (.Text property). And udfs that vary with cell formatting
should be volatile so they recalc more often, so pick up formatting
changes more frequently.
Anyway, the most general way to use the proposed txet udf would be
=IF(COUNT(X99,FIND("‚¬",txet(X99)))=2,"*0.61","")
|