HashMap in Struts

Hello,

I need some direction on how to proceed on using hashmap. I am new to this. Please advise.

I have a form with Struts validation enabled. In my form I have a drop down.Based on value from drop down. I need to load one particular value.

My form has a default value assigned to a particular field. But when something is selected from dropdown I need to overwrite that default value with the value mentioned in the Hashmap for that selected dropdown value(key).

I am using Hashmap to store the key value pairs. Now my question is where should this functionality be. Will it be in the ActionForm or in the Action class.

Can anyone explain with an example on how to proceed.

Thanks.

Message was edited by:

kris10

[799 byte] By [kris10a] at [2007-11-26 16:15:04]
# 1
Got it working. Tried in both the action class and the actionform. According to my functionality needed this in Actionform.
kris10a at 2007-7-8 22:37:58 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...