parsing hash tables in json represantation with javascript


Im having problem to parse json represantation of hash table. I made hash table in C# and then return that to client side:

string ICallbackEventHandler.GetCallbackResult()
Hashtable names = new Hashtable();
return JsonConvert.ExportToString(names);

On the client side I have this peace of code:

// Dump the JSON text response from the server.

document.forms[0].JSONResponse.value = arg; //arg is json presentatiopn of hash table

// Parse JSON text returned from callback

var categoryProducts = parseJSON("(" + arg + ")");

first part of the code works....it shows json structure, but parsing doesnt work....its not possible to show categoryProducts values


0 Replies

Recent Posts

in .NET Development