I am reporting off an ASCII comma-delimited text file. Strings are enclosed in double quotes. I am using a File DSN with the Microsoft Text Driver (ODBC). One field in the file contains a two-letter code designating a style of window, e.g., "DH" = Double-Hung, "SH" = Single-Hung, etc. I have a formula to 'translate' these codes, like this:
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = 'DH' then 'Double-Hung Window'
else
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = 'SH' then 'Single-Hung Window'
else
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = '' then 'No Style Specified'
else
'Invalid Style Code: ' & {CALLDMP_TXT.PROBLEMSTYLE}
The report is grouped by PROBLEMSTYLE and the formula object is placed in the group footer. Everything works, EXCEPT when the field in the file is empty ("". In this case, instead of printing "No Style Specified," as I would expect, it simply leaves the object blank.
I tried StrCmp, Len, and IsNull functions, all with the same results. I can find nothing like this in the Crystal Decisions KnowledgeBase.
Any ideas?
Thanks In Advance.
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = 'DH' then 'Double-Hung Window'
else
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = 'SH' then 'Single-Hung Window'
else
if Trim({CALLDMP_TXT.PROBLEMSTYLE}) = '' then 'No Style Specified'
else
'Invalid Style Code: ' & {CALLDMP_TXT.PROBLEMSTYLE}
The report is grouped by PROBLEMSTYLE and the formula object is placed in the group footer. Everything works, EXCEPT when the field in the file is empty ("". In this case, instead of printing "No Style Specified," as I would expect, it simply leaves the object blank.
I tried StrCmp, Len, and IsNull functions, all with the same results. I can find nothing like this in the Crystal Decisions KnowledgeBase.
Any ideas?
Thanks In Advance.