> From: Bender, James [mailto:[EMAIL PROTECTED] 
> The user can click
> Search Attributes | Search Components | Search Templates
> I've provided html:link's like these respectively:
> doPrepareSearch.do?searchType=attribute |
> doPrepareSearch.do?searchType=component |
> doPrepareSearch.do?searchType=template

When the user clicks one of those, Struts will populate the form
associated with (I assume) PrepareSearchAction.  Does the mapping for
that have a 'name' attribute?  Does that Form have get/setSearchType
methods?

If you need to "remember" data, it's often easiest to put the Form bean
in session scope.  And you can associate one Form to several different
Actions if it makes sense for your application.  Some people will argue
against session scope, so you may want to consult the archives and see
if their reasons apply to your situation.

> so when they user lands on my form, I want to prepopulate the 
> search type based on what they chose.

That will just magically happen if you let Struts populate the form from
the query string parameter and then use the same Form bean when you
display your HTML form using the JSP.

Rather than confuse the issue, if you still need help, post your
struts-config.xml so we can see what you've got.  

-- 
Wendy Smoak
Application Systems Analyst, Sr.
ASU IA Information Resources Management 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to