lindagoodwin
IS-IT--Management
Hi, I'm using Crystal 10. I have a report that lists the patient's address in the Page Header. A patient can have addresses in {PATIENT.PERMANENT_ADDRESS}&{PATIENT.PERMANENT_ADDRESS_2}and we needed them both if available, so I wrote this formula that worked perfectly until I had a patient with a Foreign Country address.
The formula that worked is:
if isnull({PATIENT.PERMANENT_ADDRESS_2})
then
{PATIENT.PERMANENT_ADDRESS} & Chr(13) & {PATIENT.PERMANENT_CITY}& ", "& {V_PATIENT_CONCISE.PERMANENT_STATE_CODE} &
" "
& {PATIENT.PERMANENT_ZIP_CODE}
else
{PATIENT.PERMANENT_ADDRESS} & Chr(13) &
{PATIENT.PERMANENT_ADDRESS_2} & chr (13)& {PATIENT.PERMANENT_CITY} & ", "& {V_PATIENT_CONCISE.PERMANENT_STATE_CODE}
& " "& {PATIENT.PERMANENT_ZIP_CODE}
So now I have another formula for Foreign Countries but don't know how to combine them into one formula. In Registration process if they put FC in the State Code field it opens up the Foreign Country field.
if{V_PATIENT_CONCISE.PERMANENT_STATE_CODE}="FC" then
{PATIENT.PERMANENT_ADDRESS} & Chr(13) & {PATIENT.PERMANENT_CITY}& ", "& {FOREIGN_COUNTRY.DESCRIPTION}
We don't see that many foreign country patients so I need it to default to my original formula but if the State Code = FC then print the Foreign Country formula.
I have been working on this report for months, it's very complicated and thought I finally had exactly what they wanted but now this popped up yesterday!! Please help!!!
I will appreciate any help I can get at this point!!
The formula that worked is:
if isnull({PATIENT.PERMANENT_ADDRESS_2})
then
{PATIENT.PERMANENT_ADDRESS} & Chr(13) & {PATIENT.PERMANENT_CITY}& ", "& {V_PATIENT_CONCISE.PERMANENT_STATE_CODE} &
" "
& {PATIENT.PERMANENT_ZIP_CODE}
else
{PATIENT.PERMANENT_ADDRESS} & Chr(13) &
{PATIENT.PERMANENT_ADDRESS_2} & chr (13)& {PATIENT.PERMANENT_CITY} & ", "& {V_PATIENT_CONCISE.PERMANENT_STATE_CODE}
& " "& {PATIENT.PERMANENT_ZIP_CODE}
So now I have another formula for Foreign Countries but don't know how to combine them into one formula. In Registration process if they put FC in the State Code field it opens up the Foreign Country field.
if{V_PATIENT_CONCISE.PERMANENT_STATE_CODE}="FC" then
{PATIENT.PERMANENT_ADDRESS} & Chr(13) & {PATIENT.PERMANENT_CITY}& ", "& {FOREIGN_COUNTRY.DESCRIPTION}
We don't see that many foreign country patients so I need it to default to my original formula but if the State Code = FC then print the Foreign Country formula.
I have been working on this report for months, it's very complicated and thought I finally had exactly what they wanted but now this popped up yesterday!! Please help!!!
I will appreciate any help I can get at this point!!