Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / Telerik MVC Extensions (superseded) > General Discussions > Grid is not displaying right data for Int64
Telerik MVC Extensions are no longer supported (see this page for reference). In case you have inquiries about Kendo UI Complete for ASP.NET MVC, post them in the pertinent Kendo UI forums.

Not answered Grid is not displaying right data for Int64

Feed from this thread
  • Posted on Jun 22, 2012 (permalink)

    Hi ,
    I am showing data of a table in Telerik MVC Grid.
    But Grid is not showing right values for columns with datatype Int64.

    I have put code below and attached screen shot of Database data and grid.
    See, it is always replacing last value with 0.

    Please help me to solve.

    Thanks!
    Munish S.

    @(Html.Telerik().Grid<PowerEPC.Management.DAL.AffiliatePixel>()
            .Name("Grid")
            .DataKeys(keys => keys.Add(c => c.ID))
                
            .Columns(columns =>
            {
                columns.Bound(c => c.ID).Width(150).Title("ID");          
                columns.Bound(c => c.AffiliateId).Width(80).Title("Affiliate ID");
                columns.Bound(c => c.CampaignId).Width(80).Title("Campaign ID")
                .ClientTemplate("<a href=\"PixelRule/Index?CampaignId=<#= CampaignId #>\"><#= CampaignId #></a>");
                 
                columns.Bound(o => o.PixelUrl).Width(300).Title("Pixel Url");         
                columns.Bound(o => o.ScrubPercentage).Width(50).Title("Scrub").ClientTemplate("<#= ScrubPercentage #> %");
                columns.Bound(c => c.TrackedEntityId).Width(150).Title("Tracked Entity ID");
                columns.Bound(o => o.ID).Width(60).ClientTemplate("<a  href=\"/AffiliatePixel/Edit?affiliateId=<#= AffiliateId #>&CampaignId=<#= CampaignId #>\">Edit</a>").Title("");
                columns.Bound(o => o.ID).Width(60).ClientTemplate("<a  href=\"/AffiliatePixel/Delete?affiliateId=<#= AffiliateId #>&CampaignId=<#= CampaignId #>\">Delete</a>").Title("");  
            })
              .DataBinding(dataBinding => dataBinding.Ajax().Select("_Index", "AffiliatePixel"))
                                                 .Sortable(sorting => sorting
                                            .OrderBy(sortOrder => sortOrder.Add(o => o.AffiliateId))
                                ).Scrollable()
                                                 .Pageable(paging => paging.PageSize(10)).Filterable()  
             
     
     
        )
    //
           // GET: /AffiliatePixel/
     
           public ViewResult Index()
           {
               return View();
           }
     
     
     
           [GridAction]
           public ActionResult _Index()
           {
     
               return PartialView(new GridModel<AffiliatePixel>
               {
                   Data = db.AffiliatePixels.Where(c=>c.IsDeleted==false)
               });
     
           }
    Attached files

  • Posted on Jun 29, 2012 (permalink)

    Can Some body from telerik provide me Suppor.
    i am waiting for last three days

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / Telerik MVC Extensions (superseded) > General Discussions > Grid is not displaying right data for Int64