This is a migrated thread and some comments may be shown as answers.

Grid - Bind to collection in page model

1 Answer 126 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Quinn
Top achievements
Rank 1
Quinn asked on 30 Aug 2019, 03:11 PM
public class EncountersModel : PageModel
  {
      public EncountersModel(IDataAccess dataAccess)
      {
          this.dataAccess = dataAccess;
      }
 
      public IEnumerable<Encounter> Encounters { get; set; }
           
      private readonly IDataAccess dataAccess;
 
      public void OnGet()
      {
          Encounters = dataAccess.GetOpenEncounters();
      }
  }

 

@page
@model SafeUSWeb.Pages.EncountersModel
@{
    ViewData["Title"] = "Encounters";
}
 
<h2>Encounters</h2>
 
@(Html.Kendo().Grid(Model.Encounters)
        .Name("grid")
        .Columns(columns =>
        {
            columns.Bound(c => c.EncounterId).Width(140);
            columns.Bound(c => c.EncounterType).Width(190);
            columns.Bound(c => c.Status);
            columns.Bound(c => c.Organization.OrgName).Width(110);
        })
        .HtmlAttributes(new { style = "height: 380px;" })
  )

 

When I run this I get an error that says - Failed to load resource: net::ERR_SPDY_PROTOCOL_ERROR

1 Answer, 1 is accepted

Sort by
0
Viktor Tachev
Telerik team
answered on 04 Sep 2019, 09:58 AM

Hi Quinn,

 

The error you are seeing is a browser exception that is related to the SPDY protocol. It is most likely due to using an outdated browser version. Note that this protocol is deprecated and is no longer supported by modern browsers. 

This exception should be resolved by updating the browser to the latest version. Would you update the browser you are using and let me know how the behavior changes.

 

Regards,
Viktor Tachev
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Grid
Asked by
Quinn
Top achievements
Rank 1
Answers by
Viktor Tachev
Telerik team
Share this question
or