I am trying to replicate a jquery ajax call in Script # and pass an object literal in the data parameter
{ id: target.data("id"), name: newName}
I am trying to reproduce this in Script #, but I have not been successful at this time. The first thing that came to mind was an anonymous object:
new { id = target.GetDataValue("id"), name = newName }
but this does not seem to work.
Any ideas?
source
share