xml to variable
Binu
Posts: 49
Hi
I am trying to store a xml string from my buffer to a structure by using xml_to_variable
But I could not, can some one help
struct _address
{
char name [30]
char email_id[100]
char place [100]
char age [3]
}
define_variable
_address address [20]
and in my button_event
push:
{
Value = XML_TO_VARIABLE (address, server_buffer, 1, 0)
}
The data in my buffer looks like
<address1>
<name1>bravo</name1>
<emaid1>sss@dddf.com</emailid1>
<place1>gdrkdr</place1>
<age1>44</age1>
</address1>
<address2>
<name2>bravo</name2>
<emaid2>sss@dddf.com</emailid2>
<place2>gdrkdr</place2>
<age2>44</age2>
</address2>
I am trying to store a xml string from my buffer to a structure by using xml_to_variable
But I could not, can some one help
struct _address
{
char name [30]
char email_id[100]
char place [100]
char age [3]
}
define_variable
_address address [20]
and in my button_event
push:
{
Value = XML_TO_VARIABLE (address, server_buffer, 1, 0)
}
The data in my buffer looks like
<address1>
<name1>bravo</name1>
<emaid1>sss@dddf.com</emailid1>
<place1>gdrkdr</place1>
<age1>44</age1>
</address1>
<address2>
<name2>bravo</name2>
<emaid2>sss@dddf.com</emailid2>
<place2>gdrkdr</place2>
<age2>44</age2>
</address2>
0
Comments
Download XMLPad which is a nice little app. for XML viewing and data manipulation.
I don't believe you can't arbitrarily create your onw XML format and expect this function to know how to handle it.
You can't change the structure of the XML file but you can load data offline in to an XML file and then have Netlinx load that data on an event.