質問

Actually several links are there, describing how to populate select tag in struts2 using arraylist.Drop down list in struts2. But i didnt get it. Error I got is

tag 'select', field 'list', name 'role': The requested list key '%{oList}' could not be resolved as a collection/array/map/enumeration/iterator type. Example: people or people.{name} - [unknown location]

(My list name is oList,which is already filled from action class from database)

List oList=new ArrayList();

Please help me to clear my error. I tried several. Sorry if i do any mistake.

役に立ちましたか?

解決

There should be setters and getters for your list (in your case "oList") for corresponding action class when assigning to struts select tag.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top