Have a Publisher class with attributes
Publisher --->class
name
code
 
Action class
private String[] publisherName;
List<Publisher> publishers= new ArrayList<Publisher>();
 
getters and setters for the same too in it.
 
 
JSP
                <sj:autocompleter
id="publisherNameId"

name="publisherName"

list="%{publishers}"

listValue="name"

listKey="code"

listLabel="code"

selectBox="true"

selectBoxIcon="true"

key="label.publisherName"

onChangeTopics="publisherNameChange"

onFocusTopics="publisherNameFocus"

onSelectTopics="publisherNameSelect"

size="34"

maxlength="34"

/>
 
When I don't select anything in autocompleter and submit the form seeing this 
in console
Unexpected Exception caught setting 'publisherName' on 'class 
com.xxx.createAction: Error setting expression 'publisherName' with value ['', ]
 
when I select something in autocompleter and submit the form seeing this in 
console
Unexpected Exception caught setting 'publisherName' on 'class 
com.xxx.createAction: Error setting expression 'publisherName' with value 
['macode2', ]
Unexpected Exception caught setting 'publisherName_widget' on 'class 
com.xxx.createAction: Error setting expression 'publisherName_widget' with 
value ['macode2', ]
 
Is this the right way to declare in the Action class for autocompleter?
Please need help on this.
 
                                          

Reply via email to