I’m trying to embed a JQuery string within a Razor object that access it's property....something like this:
var propertyID = $(this).attr('id');
var modelData = “@Model.InitialHistory.” + propertyID;
modelData should look something like this: @Model.InitialHistory.Property_1;
(if i type @Model.InitialHistory.Property_1; in my code it works fine, just need to dynamically select the razor property)
is something like this even possible or am I going to have to create an ajax call?
thanks!