I am using Crystal XI and I need to sort my report by user selected time parameters. I know that you cannot group by parameter selects so I am trying to create a formula to group or sort by. I am having trouble trying to extract these into a display field which might subsequently help me to sort by it.
I have played around with the first line trying to convert ?Time or by changing stringvar to timevar but I can't seem to get it to work. The formula below produces the following error:
A string is required here. If I change it to Cstr(?Time) then I get "A number, currency amount, boolean, date, time, date-time or string is required here". I have used this formula in the past for String parameters but I can't seem to get it to work for Time parameters. Any help would be appreciated. Thanks.
stringvar array params := {?Time};
numbervar i;
numbervar j := ubound(params);
stringvar display;
For i := 1 to j do
(
display := (display + params) & ","
);
Left(display,len(display)-1);
I have played around with the first line trying to convert ?Time or by changing stringvar to timevar but I can't seem to get it to work. The formula below produces the following error:
A string is required here. If I change it to Cstr(?Time) then I get "A number, currency amount, boolean, date, time, date-time or string is required here". I have used this formula in the past for String parameters but I can't seem to get it to work for Time parameters. Any help would be appreciated. Thanks.
stringvar array params := {?Time};
numbervar i;
numbervar j := ubound(params);
stringvar display;
For i := 1 to j do
(
display := (display + params) & ","
);
Left(display,len(display)-1);