Hello,
It seems that every time I get 3 steps ahead, it ends up being just 2 UGH
Im having trouble referencing other fields/objects values within an IF expression (other expressions with references have the same result).
The field NPI_1 is conditional upon 2 factors:
Field DOS_FR_1 has a value and P_SIGN has a certain name, in which will dictate the value of NPI_1
Eventually this will use elseif for 3 names and their respective id #s
Unfortunately, I cant even get the 1st part to work.
Ive tried everything I can think of - and it just wont accept the = in my expression. I keep having this problem obviously Im missing something.
Thank you sooo much for your help.
The following is the error I keep getting
FormCalc: Error: syntax error near token = on line 1, column 56.
Javascript: expected ), line 1
if ( ( HasValue(DOS_FR_1) ) and ( A.P1.P_SIGN.rawValue = "TERRY TAYLOR SMITH, LMFT" ) ) then
NPI_1.rawValue = "1508879974"
endif
if ( ( HasValue(DOS_FR_1) ),( A.P1.P_SIGN.rawValue = "TERRY TAYLOR SMITH, LMFT" ) ) then
NPI_1.rawValue = "1508879974"
endif
if ( ( HasValue(DOS_FR_1) ) and ( P_SIGN.rawValue = "TERRY TAYLOR SMITH, LMFT" ) ) then
NPI_1.rawValue = "1508879974"
endif
if ( HasValue(DOS_FR_1) and P_SIGN.rawValue = "TERRY TAYLOR SMITH, LMFT" ) then ;
NPI_1.rawValue = "1508879974"
endif
I even tried the short version:
if ( A.P1.P_SIGN = "TERRY TAYLOR SMITH, LMFT" ) then
NPI_1.rawValue = "1508879974"
endif
**PS
This works fine:
if ( HasValue(DX1) AND HASVALUE(DOS_FR_1) ) then "1"
else " "
endif
It's the = that's giving me a hard time.