Hi,Martijn: Thanks for your help.It works normally after serializing FieldInfo object. Regards, Karl.
--- Martijn Hinten <[EMAIL PROTECTED]> wrote: > See page 292 of Kent Tong's good book on Tapestry > (Enjoying WebDev w/ > Tapetry). The key is that your FieldInfo object > needs to be > serializable. > > ---- Original Message ---- > From: [EMAIL PROTECTED] > To: [email protected] > Subject: RE: Could not find a strategy instance for > class > Date: Thu, 20 Oct 2005 18:38:39 -0700 (PDT) > > >Hi,all: > > I'm a new comer for tapestry.I want to use "For" > component to > >repeat the same contents,but i got "Could not find > a strategy > >instance for class com.laniqi.crm.pages.FieldInfo". > I don't know what > >the reason is.The following is my code fragment. > > > >HTML Template file: > >... > > <tr jwcid="@For" source="ognl:crm.customers" > value="ognl:crm.info" > >element="tr"> > > <td><span jwcid="@Insert" > value="ognl:crm.info.name" > >/></td> > > </tr> > >... > > > >Page data File: > >public class CrmConfigurator > >{ > > public CrmConfigurator(){ > > FieldInfo inf = new FieldInfo(); > > inf.setName("DK"); > > customers.add(inf); > > } > > private FieldInfo info = new FieldInfo(); > > public FieldInfo getInfo() { > > return info; > > } > > public void setInfo(FieldInfo info) { > > this.info = info; > > } > > > > private List customers = new ArrayList(); // it > is used to > >contain FieldInfo object. > > public List getCustomers(){ > > return customers; > > } > >} > >Page Java File: > > public abstract CrmConfigurator getCrm(); > > public abstract void setCrm(CrmConfigurator > crm); > > > > public void pageBeginRender(PageEvent event) > > { > > > > CrmConfigurator crm = new > CrmConfigurator(); > > setCrm(crm); > > } > > > >Thanks and Regards, > >Karl. > > > > > > > > > >--------------------------------- > > Yahoo! FareChase - Search multiple travel sites in > one click. > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > > __________________________________ Yahoo! FareChase: Search multiple travel sites in one click. http://farechase.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
