Object Reference > ChartGroup Object > ChartGroup Object Methods > LoadAdoRecordset Method (ChartGroup) |
LoadAdoRecordset Method (ChartGroup)
Loads data from an ADO recordset.
Sub LoadAdoRecordset(Recordset As Object, [UseSeriesFields As Boolean = False])
This method performs a one-time static load of the recordset data (it does not provide dynamic data binding).
Part |
Type |
Description |
Recordset |
Object |
Recordset to be loaded |
UseSeriesFields |
Boolean |
Optional – if not specified, the default value is False If False, will take all fields except PointLabelsField and PointValuesField; If True, will take all fields specified in the SeriesFields |
Example
Dim aConnection As New Connection
Dim aRecordset As Recordset
Dim RecordsAffected As Long
aConnection.Open "OlData"
Set aRecordset = aConnection.Execute("DemoData", RecordsAffected, adCmdTable)
Chart2D1.ChartGroups(1).LoadAdoRecordset aRecordset
Note: A data source called 'OlData' must be created.
See Also