I have the following..
@Html.Action("Index", "Presents",
new {@Model.GroupId, @Model.PresentId, Name = @Model.CurrentName })
With the following Model..
public class MyModel
{
public long GroupId { get; set; }
public long PresentId { get; set; }
public string CurrentName { get; set; }
}
When I run the action though I am seeing CurretName as null. If I go..
@Html.Action("Index", "Presents",
new {@Model.GroupId, @Model.PresentId, Name = "@Model.CurrentName" })
I’ll get the actual text “@Model.CurrentName” for CurrentName.
Any clue how I get string values to pass properly when the source is a model?
What happens if you simply remove @ in front of Model?
Like this: