Hi all,
Not sure if I'm in the correct forum, sorry if I'm not.
Having problem with the following crystal syntax. I's only
showing some of the records information, and not all. If I take away everything except just the last "if else" statement it seems to work fine.
Local StringVar status1 := {TempERCP.Status};
Local StringVar status2 := {TempERCP.Status2};
Local StringVar status3 := {TempERCP.Status3};
Local StringVar Diag1;
IF status1 = "proven" then
(
status1 := "";
Diag1 := " Diagnosis"
)
Else
(
status1 := Replace({TempERCP.Status},left({TempERCP.Status},1),uppercase(left({TempERCP.Status},1)),1,1);
Diag1 := " diagnosis"
);
IF status2 = "proven" then
status2 := ""
Else
status2 := {TempERCP.Status2};
IF status3 = "proven" then
status3 := ""
Else
status3 := {TempERCP.Status3};
IF NOT (isnull({TempERCP.Diagnosis})) and isnull({TempERCP.Diagnosis2}) and isnull({TempERCP.Diagnosis3}) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis} + "."
Else if not (isnull({TempERCP.Diagnosis})) and not (isnull({TempERCP.Diagnosis2})) and isnull({TempERCP.Diagnosis3}) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis}
+ " and a " + status2 + " diagnosis of " + {TempERCP.Diagnosis2} + "."
Else if not (isnull({TempERCP.Diagnosis})) and not (isnull({TempERCP.Diagnosis2})) and not (isnull({TempERCP.Diagnosis3})) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis} + ", a "
+ status2 + " diagnosis of " + {TempERCP.Diagnosis2}
+ " and a " + status3 + " diagnosis of " + {TempERCP.Diagnosis3} + "."
thanks for your help
Gerry
Not sure if I'm in the correct forum, sorry if I'm not.
Having problem with the following crystal syntax. I's only
showing some of the records information, and not all. If I take away everything except just the last "if else" statement it seems to work fine.
Local StringVar status1 := {TempERCP.Status};
Local StringVar status2 := {TempERCP.Status2};
Local StringVar status3 := {TempERCP.Status3};
Local StringVar Diag1;
IF status1 = "proven" then
(
status1 := "";
Diag1 := " Diagnosis"
)
Else
(
status1 := Replace({TempERCP.Status},left({TempERCP.Status},1),uppercase(left({TempERCP.Status},1)),1,1);
Diag1 := " diagnosis"
);
IF status2 = "proven" then
status2 := ""
Else
status2 := {TempERCP.Status2};
IF status3 = "proven" then
status3 := ""
Else
status3 := {TempERCP.Status3};
IF NOT (isnull({TempERCP.Diagnosis})) and isnull({TempERCP.Diagnosis2}) and isnull({TempERCP.Diagnosis3}) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis} + "."
Else if not (isnull({TempERCP.Diagnosis})) and not (isnull({TempERCP.Diagnosis2})) and isnull({TempERCP.Diagnosis3}) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis}
+ " and a " + status2 + " diagnosis of " + {TempERCP.Diagnosis2} + "."
Else if not (isnull({TempERCP.Diagnosis})) and not (isnull({TempERCP.Diagnosis2})) and not (isnull({TempERCP.Diagnosis3})) then
status1 + Diag1 + " of " + {TempERCP.Diagnosis} + ", a "
+ status2 + " diagnosis of " + {TempERCP.Diagnosis2}
+ " and a " + status3 + " diagnosis of " + {TempERCP.Diagnosis3} + "."
thanks for your help
Gerry