Building a database chart
The main thing is to setup the system right to get the charts;
- Put a charts component on the form
- Put a dbseries component on the form
- Put a dbtable and data source on the form
- Select table and assign fields
- Bind the dbseries to the datasource
- Bind the datasource to the table
- Bind the table to the database connection
- Set the x,y fields on the dbcharts
- Set the dbtable active property to true
- Generate and run the application
Example
Suppose that we have a table like this:
With the following data:
To visualize the data the sampledate will be on the x-axis, the samplevalue on the y axis. The design is as follows
The components are set to:
Connection Table
Chart serie Chart
In this case the chart is set to bar and the result will be:
If set to line: