You need to sign in to do that
Don't have an account?

How to get Data from a Static wrapper Object in Visualforce page.
Hi all,
I have a small query that :
My senario is that I am using javascript remoting to pass data from page to controller and then fill a wrapper class(json parser).
but in javascript we can only use static variables so i made my wrapper object as public static.
Every thing work and I get the Data in controller but when I tried to write it to VF page it give me "Unknown property 'fbIntegrationDataController.id'"
So how to get Data from it I also have getter setter for that but still not able to do so.
Public static fbIntegrationDataController fbClassObj{get;set;} public static void setfbClassObj(fbIntegrationDataController f){ fbClassObj = f; } public static fbIntegrationDataController getfbClassObj (){ return fbClassObj; } @RemoteAction global static string getsetfbData(String tokenname) { fbData = tokenname; fbClassObj = parse(fbData); return ''; } public String name; public String email; public String id; public Picture picture; public class Picture { public Data data; } public class Data { public String url; public Integer width; public Integer height; public Boolean is_silhouette; } public static fbIntegrationDataController parse(String json) { return (fbIntegrationDataController) System.JSON.deserialize(json, fbIntegrationDataController.class); }
public String id {get; set;}
Let me know if it helps.
All Answers
Hello,
Please refer following links explaining this requirement with code snippets:
http://salesforce.stackexchange.com/questions/9175/visualforce-remoting-passing-wrapper-class-object-as-a-parameter
http://sfdchack.blogspot.in/2013/03/sorting-of-wrapper-class-in.html
Sorry, but didn't founf any thing relevent.
public String id {get; set;}
Let me know if it helps.
Hi Thanks man,
forgot to do that !! :)