I have a problem and I can\'t find solution. I\'m using Razor and it is my VieModel class.
public class GroupToExport
{
public GroupToExport()
{
You are using Incorrect syntax to Map the values back when they are posted, since the checked value of a checkbox is initialised to false by default, that is the reason why it is always false,use sysntax
@for(int i = 0; i < Model.ExportingGroups.Count(); i++)
{
@Html.CheckBoxFor(modelItem => Model.ExportingGroups[i].ToExport)
}
//some divs
This should map back all values you are looking for.