• Get the Flash Player to see the slideshow.
  • Categories

  • Authors

  • Great Quotes

    Which is more vital fame or health? Which is more precious health or riches? Which is more harmful loss or gain? — Lao Tzu - Tao Te Ching

Get in touch...

To have a chat about
your CMS needs...

Call us 0207 193 2014
or
Email us on

Author Archive

Getting MultipleSelect values in a Java External

Tuesday, September 23rd, 2008

It is often useful to setup a “Multi-Select Datum” in a LiveSite component, but how do you write the Java external to receive this array of parameters?

The following code snippet from Raj Shekhawat shows you how:

//LiveSite returns Multiple select values in the form of ArrayList object
//Searchproperties is my parameter name
 ArrayList selectedProperties= (ArrayList) context.getParameters().get("SearchProperties"); 
 
String selectedValues = "";
Iterator propertiesIterator = selectedProperties.iterator();
 while (propertiesIterator.hasNext()) {
             selectedValues += propertiesIterator.next();
}