Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
230
A circular reference was detected while serializing an object of type 'System.Data.Entity.DynamicProxies.ApplicationVersion_5873625B844CCA17E07B250096A709DE10780528E07321E64961938506A2A18E'.
posted

I am getting A circular reference was detected while serializing an object of type 'System.Data.Entity.DynamicProxies.ApplicationVersion_5873625B844CCA17E07B250096A709DE10780528E07321E64961938506A2A18E'. on cshmle line .Grid(Model)

Below is my code. Please let me know if you need any other information/code sample in order to answer my question.

CSHMTL

=====================================================

@using Infragistics.Web.Mvc

@model IQueryable<OTModel.ApplicationVersion>

@(Html.Infragistics()
.Grid(Model)
.ID("Grid")
.Height("500px")
.Width("100%")
.AutoGenerateColumns(false)
.AutoGenerateLayouts(false)
.RenderCheckboxes(true)
.PrimaryKey("ApplicationVersionID")
.Columns(column =>
{
column.For(x => x.ApplicationVersionID).HeaderText("Version ID").Width("10%");
column.For(x => x.VersionName).HeaderText("Version Name").Width("50%");
column.For(x => x.IsActive).HeaderText("Is Active").Width("25%");

})
.Features(feature =>
{
feature.Updating().ColumnSettings(cs =>
{
cs.ColumnSetting().ColumnKey("ApplicationVersionID").ReadOnly(true);
cs.ColumnSetting().ColumnKey("VersionName").Required(true).TextEditorOptions(o => o.ValidatorOptions(vo => vo.MinLength(4).KeepFocus(ValidatorKeepFocus.Never)));
cs.ColumnSetting().ColumnKey("IsActive").Required(true) ;

});
feature.Sorting();
})
.DataSourceUrl(Url.Action("GetApplicationVersions"))
.UpdateUrl(Url.Action("OrdersSaveData"))
.DataBind()
.Render()
)

CONTROLLER

=============================


ApplicationVersion av = OTControlPanelBL.GetApplicationVersionByApplicationID(id).AsQueryable();

return View(av);

Above return list of records, in the above case 4 records

===================================

Parents
No Data
Reply Children