I am new to Flex n right now playing with the most used
I have a List control and a DataGrid. I want to drag and drop
a item from List to DataGrid.
Now what i want is
Not all but some specific columns should get populated.
Now according to me the solution is ...
1) override the dragDropHandler(event:DragEvent) of DataGrid
2) get the dragSource from event object.
3) somehow remove the column specific data that we dont want
4) set the dragSource data again to event object and call
this is the code..
override protected function
var dragData:Object =
var dgColumn:MyDGColumn; // my custom DataGridColumn with
arrColumns = this.columns;
dgColumn = arrColumns
if(dgColumn.populateOnDrop != true)
// don't know waht to do here. //pls suggest somthing how to change the value in the
dragSource for this column to empty string
// here assign changed dragSource to event object.
pls suggest if there is another way to do it..
Thanx in advance...
You don't really have to call super.dragDropHandler().
It really depends what kind of properties you have in
dragData object and what kind or properties you have in the
underlying data source of the data grid.
All you need to do is to instantiate a new object of type
that are in the underlying data source of the grid, copy properties
from the dragged data source and insert the new object into the
array collection of the data grid.