Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8546611
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T13:04:23+00:00 2026-06-11T13:04:23+00:00

I am having difficulty getting the data to show in a Telerik Grid control.

  • 0

I am having difficulty getting the data to show in a Telerik Grid control. I populate a list object GraphDetail in my ViewModel. Then try to use Model.GraphDetail to bind the data to the grid in the view. The project compiles and runs without error and the grid does show but it is empty. If I step through the code I can see that the GraphDetail is being populated with data.

Here is my ViewModel:

namespace AESSmart.ViewModels
{
    public class ACVoltagesTelerikGraph
    {
        public long InverterID { get; set; }
        public string InverterName { get; set; }
        public double? voltage_ac_a { get; set; }
        public double? voltage_ac_b { get; set; }
        public double? voltage_ac_c { get; set; }
        public DateTime recordTime { get; set; }
    }

    public class GraphsACVoltagesViewModel
    {
        public DateTime startingDate { get; set; }
        public DateTime endingDate { get; set; }

        public string HCSeries { get; set; }
        public List<ACVoltagesTelerikGraph> GraphDetail { set; get; }

        public void setLists()
        {
            //Code to populate InverterGoups and Inverters
        }

        public void setSeries()
        {
            //Code to populate GraphDetail and HCSeries
        }
    }
}

My View contains the following code to display the grid:

@model AESSmart.ViewModels.GraphsACVoltagesViewModel

@(Html.Telerik().Grid(Model.GraphDetail)
    .Name("Grid")
    .DataBinding(dataBinding => dataBinding.Server())
    .Columns(columns =>
    {
        columns.Bound(o => o.InverterID).Title("InverterID").Width(25);
        columns.Bound(o => o.InverterName).Title("InverterName").Width(100);
        columns.Bound(o => o.voltage_ac_a).Title("Phase 1 Volts").Width(75);
        columns.Bound(o => o.voltage_ac_b).Title("Phase 2 Volts").Width(75);
        columns.Bound(o => o.voltage_ac_c).Title("Phase 3 Volts").Width(75);
        columns.Bound(o => o.recordTime).Title("Record Time").Width(150);
    })
    .Groupable()
    .Sortable()
    .Filterable()
    .Pageable(pager => pager.PageSize(3))
)

Here is a screenshot of the result:
enter image description here

As you can see from the screenshot the grid is empty. So, how do I properly bind the GraphDetail list I have in my ViewModel to the grid?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T13:04:25+00:00Added an answer on June 11, 2026 at 1:04 pm

    I actually encountered a very similar problem. I could not get the graph to populate based on a list. In order to fix it I had to change the list to a collection. Try to use the following code for your scenario:

    public virtual ICollection<ACVoltagesTelerikGraph> GraphDetail { set; get; }
    

    Also, it looks like you are building the data as part of a larger class in the ViewModel. So, your controller is not going to be exclusively handling the creation of the model the grid is using. So, ‘server binding’ probably won’t work for you. Not to mention, it looks like you are just trying to show the data to the user and not needing them to modify it at all. So I would databind on the client side like so:

    @(Html.Telerik().Grid(Model.GraphDetail)
        .Name("Grid")
        .DataBinding(dataBinding => dataBinding
            .Ajax()
            .OperationMode(GridOperationMode.Client)           
        )
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having difficulty getting GNUplot to properly render some of my data. Basically I
I'm having a lot of difficulty getting core data to work in my application.
I'm having difficulty getting the binding to fire off on a user control that
I am having difficulty getting rid if the following error: bash-3.00$ p4 login Enter
I am having difficulty getting multiple jPicker instances of the same type to display
I'm having difficulty getting XQuery to work. I downloaded Saxon-HE 9.2. It seems to
I am having difficulty getting several mod_rewrite rules to work together in my .htaccess
I am having difficulty getting rid of duplicate entries which are showing up in
I'm having great difficulty getting my Android application to play videos from the SD
I am having real difficulty getting my head around the issue of setting the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.