User Guide
292 DataGrid component (Flash Professional only)
Example
The following example sets horizontal scroll policy to automatic, which means that the
horizontal scroll bar appears if it’s necessary to display all the content:
my_dg.setSize(150, 100);
// Add columns to grid and add data.
var myDP_array:Array = new Array();
myDP_array.push({name:"Clark", score:3135});
myDP_array.push({name:"Bruce", score:403});
myDP_array.push({name:"Peter", score:25});
my_dg.dataProvider = myDP_array;
my_dg.hScrollPolicy = "on";
DataGrid.removeAllColumns()
Availability
Flash Player 6 (6.0.79.0).
Edition
Flash MX Professional 2004.
Usage
myDataGrid.removeAllColumns()
Parameters
None.
Returns
Nothing.
Description
Method; removes all DataGridColumn objects from the data grid. Calling this method has no
effect on the data provider.
Call this method if you are setting a new data provider that has different fields from the
previous data provider, and you want to clear the fields that are displayed.