Hey,

Try to replace List by ArrayList in your class, it should be fine :).

Nicolas

From: May Lwin [mailto:maylwi...@gmail.com]
Sent: Tuesday, May 24, 2011 5:29 PM
To: jxls-user@lists.sourceforge.net
Subject: [jXLS-user] 
net.sf.jxls.parser.ExpressionCollectionParser.findCollectionProperties@104![0, 
27]

Dear Sir,

When I tried to write Excel file using XLS template, there are some warning 
messages with collections in the console as the followings though I was able to 
see the expected Excel output. Because of huge amount of warning message with 
collection value retrieval, the application log file size are unexpectedly big 
as we have to write excel file for thousands of records. Please provide us the 
advice how we can achieve to avoid these warning messages. Thanks in advance. 
The followings are the warning messages.

24 May 2011 23:11:52] WARN [org.apache.commons.jexl2.JexlEngine] - 
net.sf.jxls.parser.ExpressionCollectionParser.findCollectionProperties@104![0,27]:
 'member.value;' undefined variable member.value
24 May 2011 23:11:52] WARN [org.apache.commons.jexl2.JexlEngine] - 
net.sf.jxls.parser.ExpressionCollectionParser.findCollectionProperties@104![0,27]:
 'member.value;' undefined variable member.value
24 May 2011 23:11:52] WARN [org.apache.commons.jexl2.JexlEngine] - 
net.sf.jxls.parser.ExpressionCollectionParser.findCollectionProperties@104![0,27]:
 'member.value;' undefined variable member.value
The followings are sample object models, test case and jxls syntax.

public class User {
    private String username;
    private List<PhoneNumber> phoneNumbers;

    public List<PhoneNumber> getPhoneNumbers() {
       return phoneNumbers;
    }
}

public class PhoneNumber {
   public String ext;
   public String value;
}

JXLS syntax
<jx:forEach items="${memberList}" var="member">
${member.getPhoneNumbers().get(0).value}
</jx:forEach>

Thanks in advance.
Best regards,
may
------------------------------------------------------------------------------
vRanger cuts backup time in half-while increasing security.
With the market-leading solution for virtual backup and recovery, 
you get blazing-fast, flexible, and affordable data protection.
Download your free trial now. 
http://p.sf.net/sfu/quest-d2dcopy1
_______________________________________________
jXLS-user mailing list
jXLS-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jxls-user

Reply via email to