PDA

View Full Version : Declare ext config object as string



extnewbie
18 Aug 2008, 1:43 AM
Hi,

I want to make ext objects from (manipulated) json string data, sent from the server. But first I want to test.

My question is: How do I make (declare) a ext config object as a string (syntax), so I can do string manipulation on it before i pass it to
Ext.ComponentMgr.create(Ext.decode(string)); that puts it on the screen?

Thanks!

18 Aug 2008, 6:17 AM
yes you can, but i would suggest writing a singleton that does the encoding inside of a try catch block - just in case the server sends garbage. this way the app doesn't blow up.

mjlecomte
18 Aug 2008, 6:28 AM
This might help: http://extjs.com/forum/showthread.php?p=207855#post207855