Visual Basic Concepts
Binding Your Hierarchical FlexGrid to a Data Environment
Before you can use bands in your Hierarchical FlexGrid, you bind the FlexGrid to a Data Environment, which contains a top-level, parent Command object.
To bind your Hierarchical FlexGrid control to a Data Environment
- Drag a MSHFlexGrid control onto a Visual Basic form.
- From the Visual Basic Properties window, set the DataSource property to the DataEnvironment object that contains the Command object that you want to bind to the Hierarchical FlexGrid control. For example, DataEnvironment1.
- From the Visual Basic Properties window, set the DataMember property to a top-level, parent Command object in your Data Environment. Your data is now bound to a Hierarchical FlexGrid control.
- To view the data in the Hierarchical FlexGrid, select Start from the Run menu or press F5. The structure is retrieved and appears in the Hierarchical FlexGrid.