Using CR 8.5, I have twelve (12) formulas that look like
// In row 2
whileprintingrecords ; numbervar monthStart ;
if monthStart = 12 then "Januar"
else if monthStart = 1 then "Februar"
else if monthStart = 2 then "Marz"
etc for each month
and
//in row 3
whileprintingrecords ; numbervar monthStart ;
if monthStart = 11 then "Januar"
else if monthStart = 12 then "Februar"
else if monthStart = 1 then "Marz"
etc for each month
Once complete, I need to create the same report in English, French and Dutch
I would like to create an array with the month names, so I can update it in ONE place and all formulas will follow. Remember, there are twelve formulas each with twelve entries and then four languages
I started with
whileprintingrecords ; stringvar array monthNameDef ;
monthNameDef[1] := "Januar";
monthNameDef[2] := "Februar";
monthNameDef[3] := "Marz" ;
Then trying to apply, I used the definition as
whileprintingrecords ; stringvar array monthNameDef ;
monthNameDef[1] := "Januar";
monthNameDef[2] := "Februar";
monthNameDef[3] := "Marz" ;
etc
But in using it as follows, I get the "a subscript must be between 1 and the size of the array" error.
whileprintingrecords ; numbervar monthStart ; stringvar array monthNameDef ;
if monthStart = 1 then monthNameDef[1] //"Januar"
else if monthStart = 2 then monthNameDef[2] //"Februar"
else if monthStart = 3 then monthNameDef[3] //"Marz"
Please help
// In row 2
whileprintingrecords ; numbervar monthStart ;
if monthStart = 12 then "Januar"
else if monthStart = 1 then "Februar"
else if monthStart = 2 then "Marz"
etc for each month
and
//in row 3
whileprintingrecords ; numbervar monthStart ;
if monthStart = 11 then "Januar"
else if monthStart = 12 then "Februar"
else if monthStart = 1 then "Marz"
etc for each month
Once complete, I need to create the same report in English, French and Dutch
I would like to create an array with the month names, so I can update it in ONE place and all formulas will follow. Remember, there are twelve formulas each with twelve entries and then four languages
I started with
whileprintingrecords ; stringvar array monthNameDef ;
monthNameDef[1] := "Januar";
monthNameDef[2] := "Februar";
monthNameDef[3] := "Marz" ;
Then trying to apply, I used the definition as
whileprintingrecords ; stringvar array monthNameDef ;
monthNameDef[1] := "Januar";
monthNameDef[2] := "Februar";
monthNameDef[3] := "Marz" ;
etc
But in using it as follows, I get the "a subscript must be between 1 and the size of the array" error.
whileprintingrecords ; numbervar monthStart ; stringvar array monthNameDef ;
if monthStart = 1 then monthNameDef[1] //"Januar"
else if monthStart = 2 then monthNameDef[2] //"Februar"
else if monthStart = 3 then monthNameDef[3] //"Marz"
Please help