I think there's a wiki article on it, but the two most common ways to get a reference to a component are to
1) bind it to your backing bean 2) use "findComponent" on it (requires hardcoding the id somewhere). On 2/8/06, Michael Heinen <[EMAIL PROTECTED]> wrote: > > > > Hi all, > > > > I have to clear some form fields in an ActionListener method. > > The method is called with the immediate=true attribute. > > > > I found in the WIKI an article about ClearInputComponents. > > There is following snippet: > > > > component.setSubmittedValue(null); > > // The following is only needed for immediate input components > > // but it won't do any harm in other situations.. > > component.setValue(null); > > component.isLocalValueSet(false); > > > > I don't know how to retrieve the components. > > > > My BackingBean (called DynaControllerBean) has an attribute called article > of type Article. > > Article is just a simple class with a Map containing dynamic attributes: > > > > private Map<String, Object> datafieldMap = new HashMap<String, > Object>(); > > > > The jsp contains some fields, that should be cleared in the ActionListener. > > These fields are defined like the following: > > > > <t: inputText id="name" > value="#{DynaControllerBean.article.datafield['name']}"/> > > > > What have I to do now in order to set the submitted values of my article to > null in an ActionListener? > > Can anybody show me the right way to access the component and call > setSubmittedValue ? > > > > Thanks for any help