Environment: ASP.net MVC:
Given anonymous structure as such:
var test = new
{
name = "me",
age = "100"
};
that then gets parsed as
result = Json(test)
data = result.Data // Comes back with { name = "me", age = "100" }
Which then gets successfully passed into a JS function, how do I go about using that as a JSON object, so that I can do something like
function(data) // Where data = { name = "me", age = "100" } or similar
{
var name = data.name // "me"
}