View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Russ Russ is offline
external usenet poster
 
Posts: 4
Default IF statement problem with IMAGINARY

Hi: I have a cell, B31, that contains an imaginary number (69.2 +
39.4i). I want to do the following using the IF function (psuedo code
below):

IF IMREAL(B31) = 0

TRUE Then evaluate to "ATAN(IMAGINARY(B31) / 0.0000001"

FALSE Then evaluate to "ATAN(IMAGINARY(B31)/IMREAL(B31))"

The TRUE part works properly and evaluates to a number. The FALSE part
doesn't work and just puts the text "ATAN(IMAGINARY(B31)/IMREAL(B31))"
in the cell.

What am I doing wrong?

thanks,
russ