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

how to fill RadhtmlChart programmatically

1 Answer 460 Views
Chart (HTML5)
This is a migrated thread and some comments may be shown as answers.
Olivier
Top achievements
Rank 1
Olivier asked on 17 Aug 2016, 09:12 PM

Hy

i am using RadhtmlChart  and i want to fill RadhtmlChart programmatically using simple SQL request.

 

thank you very much

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 18 Aug 2016, 08:22 AM

Hi Olivier,

I advise that you start from the following articles to see how data binding the control works:

  1. http://docs.telerik.com/devtools/aspnet-ajax/controls/htmlchart/data-binding/overview
  2. http://docs.telerik.com/devtools/aspnet-ajax/controls/htmlchart/data-binding/sqldatasource

The examples show a declared control, but you can easily create it in the code-behind like any other control.

If you will also be obtaining the data in the code-behind, the following article shows how you can data bind the chart to a custom structure: http://docs.telerik.com/devtools/aspnet-ajax/controls/htmlchart/data-binding/generic-list-of-custom-objects and the following one shows hot to use a DataSet: http://docs.telerik.com/devtools/aspnet-ajax/controls/htmlchart/data-binding/dataset.

You may also find useful the following article on creating series items programmatically and mixing that with data binding: http://docs.telerik.com/devtools/aspnet-ajax/controls/htmlchart/data-binding/setting-explicit-items.

Regards,

Marin Bratanov
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Tags
Chart (HTML5)
Asked by
Olivier
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or