Hi all, I learned some from the discussion here but I have an issue opposite to what Greg faced. When I remove the translate component parameter, I get exceptions that the translate parameter could not be null !
This is my container page java file: ------------------------------------------------------------------------------------------------------------------------ package com.skycomm.tclagent.pages.editors; @SuppressWarnings("unused") public class POP3ParametersPage { @Property @Environmental private PropertyEditContext context; @Component(parameters = { "value=context.propertyValue", "label=prop:context.label", "clientId=prop:context.propertyId", "annotationProvider=context"/*, "translate=prop:gatewayTranslator"*/}) private TextField gateway; public POP3TestData getPop3() { return (POP3TestData) this.context.getPropertyValue(); } } ------------------------------------------------------------------------------------------------------------------------ page tml file: <t:block id="pop3" xmlns:t=" http://tapestry.apache.org/schema/tapestry_5_1_0.xsd" xmlns:p="tapestry:parameter"> <t:label for="gateway"/> <t:textfield t:id="gateway" size="10" t:value="pop3.gateway"/> </t:block> ------------------------------------------------------------------------------------------------------------------------ Module contributions: public static void contributeDefaultDataTypeAnalyzer(MappedConfiguration<Class, String> configuration) { configuration.add(POP3TestData.class, "pop3Parameters"); } public static void contributeBeanBlockSource(Configuration<BeanBlockContribution> configuration) { configuration.add(new EditBlockContribution("pop3Parameters", "editors/POP3ParametersPage", "pop3")); } ------------------------------------------------------------------------------------------------------------------------ I should add more fields in the future but I'm just trying to get this one work (i.e. gateway) I also find that translators will aim to display and parse whole objects through 1 field which is not my target here. I need to display all object variables into separate fields. Also is there a way to automatically display an object un fields just like beaneditor does usually ? Thank you for your time :) On Fri, Jun 3, 2011 at 6:45 AM, Greg Pagendam-Turner <g...@liftyourgame.com>wrote: > Thanks Thiago, > > I actually do have a DataTypeAnalyzer in my AppModule > > public static void > contributeDefaultDataTypeAnalyzer(MappedConfiguration<Class, String> > configuration) > { > configuration.add(PersonName.class, "personname"); > } > > Looks like if I take out the translator references everything works > correctly. > > Regards, > > Greg > > > > On 3/06/2011 12:48 AM, Thiago H. de Paula Figueiredo wrote: > >> On Thu, 02 Jun 2011 04:31:55 -0300, Greg Pagendam-Turner < >> g...@liftyourgame.com> wrote: >> >> Hi all, >>> >> >> Hi! >> >> I've also written a translator: >>> >> >> Why? A translator is used when you want to edit a property which isn't a >> String with one text field, and this isn't your case. >> >> Your code is missing a DataTypeAnalyzer to define a type for PersonName. >> Otherwise, Tapestry will not use your edition block. >> >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > > -- *Regards,* *Muhammad Gelbana Java Developer*