I just figured it out as this email came screaming in - I thought that you actually had to change the literal: to message:, which you do not. It will look for that literal key in the .properties and use it if it is there, otherwise use just the string. This seems out of sync with the displayName binding on fields such as TextField, where you do have to specify message: rather than literal: Should things be a little more consistent between the two, since both are in effect doing the same thing? -mike
________________________________ From: Robert Zeigler [mailto:[EMAIL PROTECTED] Sent: Fri 1/13/2006 11:08 AM To: Tapestry users Subject: Re: Pulling properties for Table via annotations contrib:table tries to use a property file by default. Make your column id match your message id. Your table definition could be as simple as: @Component (id="personTable",type="contrib:Table", bindings={"source=person","columns=name,dateOfBirth,gender"} ) And your .properties file: name=Name gender=Gender dateOfBirth=Date of Birth Robert Michael Melvin wrote: > Hey all, > > Just monkeying around here, trying to get the column definition for a table > working properly, and I seem to not quite be getting it: > > > @Component (id = "personTable", > type = "contrib:Table", > bindings = {"source=person", > "columns=literal:Name:name," + > "Date of Birth:dateOfBirth," + > "Gender:gender,"}) > > The above works fine with the literal: tag. However I would prefer to pull > the names out of the .properties file rather than hard-coding the strings in > the Java classes. > > The properties file currently looks like: > > name-label=Name > date-of-birth-label=Date of Birth > gender-label=Gender > > > > I have tried using message: rather than literal: , but that does not seem to > actually pull the values from the properties files. I end up getting NAME, > DATEOFBIRTH and GENDER instead. > > Any suggestions? > > -mike > > > > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
