if anyone can help me to solve my problem it would be nice
thanks everybody
Announcement
Collapse
No announcement yet.
X
-
i try this:
Code:recipientTo = new DataSourceEnumField( "recipientTo", "recipientTo" ); recipientTo.setValueXPath( "//response/data/records/message/recipientTo" );
"\n "
and this :
Code:recipientTo = new DataSourceTextField( "recipientTo", "recipientTo" ); recipientTo.setValueXPath( "//response/data/records/message/recipientTo/Address" );
glev4retbe12345706@gmail.com
Any help ?
Leave a comment:
-
In this case getAttributeAsObject should return you a JavaScriptObject that contains the data in the recipientTo subelement.
You could instead "flatten" the data model using DataSourceField.valueXPath.
Leave a comment:
-
Multiline XML response
Hi, i have a little problem :
I have a DataSource Associate to a form that i dont display (i reuse the response ):
Code:Criteria c = new Criteria(); c.addCriteria( "uid", record.getAttribute( "uid" ) ); c.addCriteria( "folderURL", record.getAttribute( "folderURL" ) ); Temp.fetchData( c, new DSCallback() { public void execute( DSResponse response, Object rawData, DSRequest request ) { ................................................................................... }
In the rest side, i return to client the following xml :
Code:<response> <status>0</status> <startRow>0</startRow> <endRow>1</endRow> <totalRows>1</totalRows> <data> <records> <message> <subject></subject> <sentDate>2009-02-27 12:22:08.0 CET</sentDate> <size>3662</size> <from>fayssal161466979@free.fr</from> <recipientTo> <Address>glev4retbe12345706@gmail.com</Address> <Name>Ben</Name> <Address>bob@bob.bob</Address> <Name>Bob</Name> </recipientTo> <uid>474</uid> <folderURL>gvfdg</folderURL> <summary>dfsg</summary> <content>dsfg</content> <seen>true</seen> <gotAttachment>dfsg</gotAttachment> </message> </records> </data> </response>
On client size i try to get recipientTo,but without any success :
Code:ListGridRecord[] li = response.getData(); li[0].getAttributeAsObject( "recipientTo" );
Any suggestion to get this data?
Regards BenTags: None
Leave a comment: