Script Guide

S@gittarius
Posts: 98
Joined: Sat May 08, 2010 8:12 pm

Re: Script Guide

Post by S@gittarius »

Hi Eugene,
Could you please provide some help to parse a JSON string into an object.
I did a lot of testing in WMS using JScript as programing language but without success.
How to make the following working?

Code: Select all

var o, s = '{"p1":"test1", "p2":"test2"}';
     o = JSON.parse(s);
     showmessage(o.p2)
Also something like

Code: Select all

o = {};
keeps on giving 'Expression expected' error.
Regards!
Post Reply