if (set == null)
{
set = "";
}
if (set != null && !"".equals(set)){
VariableSubstitutor vs = new VariableSubstitutor(idata.getVariables());
set = vs.substitute(set, null);
}
StringTokenizer tokenizer = new StringTokenizer(choiceValues, ":");
int counter = 0;
while (tokenizer.hasMoreTokens())
{
String token = tokenizer.nextToken();
listItem = new TextValuePair(token, token);
field.addItem(listItem);
if (set.equals(token))
{
field.setSelectedIndex(field.getItemCount() - 1);
}
counter++;
}
}
else
{
listItem = new TextValuePair(getText((XMLElement) choices.elementAt(i)),
((XMLElement) choices.elementAt(i)).getAttribute(COMBO_VALUE));
field.addItem(listItem);
String set = ((XMLElement) choices.elementAt(i)).getAttribute(SET);
if (set != null)
{
if (set != null && !"".equals(set)){
VariableSubstitutor vs = new VariableSubstitutor(idata.getVariables());
set = vs.substitute(set, null);
}
if (set.equals(TRUE))
{
field.setSelectedIndex(i);
}