E4X parsing problem

Questions, tips and tricks and techniques for scripting in Servoy

E4X parsing problem

Postby mboegem » Sat Nov 05, 2011 12:02 am

Hi everyone,

I'm trying to put together XML for a request to a soap server.
Normally I use this syntax to do this via the E4X implementation in Servoy, which works fine:
Code: Select all
var _trans = <transaction/>


However, when I try to do this:
Code: Select all
var _envelope = <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"/>;


I get the attached error when saving the method.
AST Parser problem.png
AST Parser problem
AST Parser problem.png (35.46 KiB) Viewed 2686 times

I could just write the XML as a string, because that's what is gonna happen anyway when posting it.
Still like the structured E4X way better... any chance this is going to work?
Marc Boegem
Solutiative / JBS Group, Partner
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image

Partner of Tower - The most powerful Git client for Mac and Windows
User avatar
mboegem
 
Posts: 1743
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: E4X parsing problem

Postby jcompagner » Tue Nov 08, 2011 11:17 am

i can use that declaration in Servoy 6.
For 5 you have to use a string or move to 6 for better E4X support
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8829
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: E4X parsing problem

Postby mboegem » Tue Nov 08, 2011 2:14 pm

thnkx Johan
Marc Boegem
Solutiative / JBS Group, Partner
• Servoy Certified Developer
• Servoy Valued Professional
• Freelance Developer

Image

Partner of Tower - The most powerful Git client for Mac and Windows
User avatar
mboegem
 
Posts: 1743
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam


Return to Methods

Who is online

Users browsing this forum: No registered users and 3 guests