Hi Guys,
can you please help with what might be the problem here?
Below is a datagrid with validation on the columns for [Required} but hopefully you can see from the screen shot that there is definitely data in the edit fields.
the columns are declared as below
<GridColumn Field=@nameof(AddEditServiceDTO.Id)
HeaderText="ID" IsPrimaryKey="true" Visible="false"
Width="50" MinWidth="50" MaxWidth="50">
</GridColumn>
<GridColumn Field=@nameof(AddEditServiceDTO.Code)
HeaderText="Code"
Width="100" MinWidth="100" MaxWidth="100"
ValidationRules="@(new ValidationRules{ Required= true, MaxLength=DTOLibrary.DbFieldLengths.Services.Code })">
</GridColumn>
<GridColumn Field=@nameof(AddEditServiceDTO.Description)
HeaderText="Description"
ValidationRules="@(new ValidationRules{ Required= true, MaxLength=DTOLibrary.DbFieldLengths.Services.Description })">
</GridColumn>
and the AddEditDTO class is defined as
public class AddEditServiceDTO
{
public int Id { get; set; }
public string Code { get; set; }
public string Description { get; set; }
}
So I am not 100% sure what I have done differently to the examples, except that I am capturing the OnActionBegin event to add and save the records
thanks,
Jeremy