A circular reference was detected while serializing an object of type System.Data.Entity.DynamicProxies
New DiscussionI 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.
@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
Sign In
to post a reply
Replies
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Favorites
0 Replies
14 Created On
Jul 15, 2015 Last Post
10 years, 7 months ago