ok, so generate the String returned by getTableColumns() at runtime...
ra wrote: > > Daniel Jue wrote: > >> I recently found a solution due to some help on this mailing list. >> >> Here's what we came up with. It displays a table of people, and the >> extent of people details are not known until runtime (i.e. should we >> display the first name, last name, email, etc) >> >> In the page file: >> >> <component id="table" type="Contrib:Table"> >> <binding name="source" value="users"/> >> <binding name="columns" value="tableColumns"/> >> <binding name="columnsClass" value="literal:title"/> >> <binding name="pageSize" value="10"/> >> </component> >> >> In your class for that page have this method: >> >> public String getTableColumns() >> { >> //For reference >> //Column id:Column Title:ognl expression >> //value="literal:id, firstName:First name:name.firstName, >> // lastName:name.lastName, telNo"/> >> >> return >> "data0:ID:getUserDetails('USERGUID'),data1:Email:getUserDetails('EMAIL'),data2:First >> Name:getUserDetails('FIRSTNAME'),data3:Last >> Name:getUserDetails('LASTNAME')"; >> >> > > Sorry it doesn't help. As I wrote I don't know column names at development > time. I don't know even the class name because model is created during > runtime. I can give more details if it's not clear > > > -- Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr Tapestry / Tacos developer Open Source / J2EE Consulting --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]