Hi, On Mon, Mar 22, 2010 at 5:55 PM, Hugh Hulme <[email protected]> wrote:
> Thank you, Guillaume - that's perfect. > You bet it is ;-) How does .getValue() differ from .display() ? > .display() is rendered, .getValue() isn't. Guillaume > -----Original Message----- > From: [email protected] [mailto:[email protected]] On Behalf > Of Guillaume Lerouge > Sent: 22 March 2010 4:47 PM > To: XWiki Developers > Subject: Re: [xwiki-devs] PropertyClass questions > > Hi Hugh, > > On Mon, Mar 22, 2010 at 5:42 PM, Hugh Hulme <[email protected]> > wrote: > > > Hi, me again :) > > > > Firstly, thank you for your help so far - it is hugely appreciated. > > > > On to the question: I searched xwiki.org for PropertyClass and found > > only release notes. I'm looking for a way to determine if a value has > > been entered into a text field, so that I can omit the entire section > > from the sheet if it's empty. > > > > Maybe: > > #if($doc.getValue('yourproperty') != '') > * ${class.get('yourproperty').prettyName}: > ${doc.display('yourproperty')} #end > > Guillaume > > First I guessed that there would be a length() property on a string, but > > was unsuccessful. Then I guessed from the VTL Reference & User Guide > > that I might be able to use size(), if a string was actually a char[], > > > but was disappointed. Any clues? > > > > Thanks again, > > - Hugh > > _______________________________________________ > > devs mailing list > > [email protected] > > http://lists.xwiki.org/mailman/listinfo/devs > > > > > > -- > Guillaume Lerouge > Product Manager - XWiki SAS > Skype: wikibc > Twitter: glerouge > http://guillaumelerouge.com/ > _______________________________________________ > devs mailing list > [email protected] > http://lists.xwiki.org/mailman/listinfo/devs > _______________________________________________ > devs mailing list > [email protected] > http://lists.xwiki.org/mailman/listinfo/devs > -- Guillaume Lerouge Product Manager - XWiki SAS Skype: wikibc Twitter: glerouge http://guillaumelerouge.com/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs

