I hope this is an easy one. I am making a custom parameter for my implementation team. I have one parameter that has 4 preset names such as 1_Name, 2_Name, 3_Name, and 4_Name. What I am doing is looking at the first position, which are the numbers and using them as identifiers for fields in the database. So in the code I look for the first positon of the string by doing something like this "1"=name[1]. So I look specifically at the first position. This way the implementer can name the default values based on the customers needs.
This idea works perfectly for single selections. However, when I have the multiple selection feature on, I can only get the first selection. Here is an example of the code:
stringVar MyText := "";
if "1" in {?Activity Description}[1] then
MyText:= MyText + {value.activity1} + " " ;
if "2" in {?Activity Description}[1] then
MyText:= MyText + {value.activity2} + " " ;
if "3" in {?Activity Description}[1] then
MyText:= MyText + {value.activity3} + " " ;
if "4" in {?Activity Description}[1] then
MyText:= MyText + {value.activity4} + " " ;
MyText;
As you can see I am taking the database values and grouping them as one string. Does anyone know how crystal groups multiple values? Are they comma seperated? I just want to be able to look at the first position for the selected values. If any one has any ideas please let me know. Thanks.
Eddie
This idea works perfectly for single selections. However, when I have the multiple selection feature on, I can only get the first selection. Here is an example of the code:
stringVar MyText := "";
if "1" in {?Activity Description}[1] then
MyText:= MyText + {value.activity1} + " " ;
if "2" in {?Activity Description}[1] then
MyText:= MyText + {value.activity2} + " " ;
if "3" in {?Activity Description}[1] then
MyText:= MyText + {value.activity3} + " " ;
if "4" in {?Activity Description}[1] then
MyText:= MyText + {value.activity4} + " " ;
MyText;
As you can see I am taking the database values and grouping them as one string. Does anyone know how crystal groups multiple values? Are they comma seperated? I just want to be able to look at the first position for the selected values. If any one has any ideas please let me know. Thanks.
Eddie