Posted by: Sameer on: April 25, 2008
i want http service by using faultevent output in xml fromat.
any examples is there.
Hey Sameer,
I have grouped data using a field(some numeric data) and at group level iam showing different field(String value) using groupLabelFunction.
group.label has been set to datafield of first column.
I need to sort my groups based on their label rather then their grouping field.
suppose my groups comes out to be
OOO
OO1
after applying label function in place of OOO-SAM
OO1-ALI.Now when I sort in ascending order it gives SAM after that
ALI.But actually it should be ALI n then SAM.I think it is comparing numeric value
thx dude
Hi Sameer,
I have also implemented dynamic grouping of columns in AdvancedDataGrid but in a slightly different way.I have extended the AdvancedDataGridRenderer to provide a drop-down menu with options like Dynamic grouping etc.You can dynamically group on a column by choosing the menu option for that column.But i am facing one issue in this regard.I am able to dynamically group only once.The reason for it is as follows :
My initial dataProvider is an ArrayCollection.But when i dynamically group based on the chosen column then the dataProvider becomes a Hierarchical Data.Hence when i click on another column then it gives type mismatch error. Is there a way that i can reset the grid’s dataProvider to the initial ArrayCollection ? Could you please tell me how should i proceed with the above problem.
private function menuOptionHandler(event:MenuEvent):void
{
var groupingCollection:GroupingCollection= new GroupingCollection();
var grouping:Grouping = new Grouping();
var groupingField:GroupingField = new GroupingField (gridColumn.dataField);
grouping.fields = new Array()
///////Error here //////////
groupingCollection.source = ICollectionView(grid.dataProvider);
grouping.fields.push(groupingField);
groupingCollection.grouping = grouping;
groupingCollection.refresh();
//grid.dataProvider initially ArrayCollection – changes to Hierarchical //here
grid.dataProvider = groupingCollection;
}
Regards,
Shishir.
Hi Sameer,
Oops i checked your proposed solution just now
. I have replied to it .
Thanks,
Shishir.
Hi sameer,
I am using groupLabelFunction in my custom Datagrid component. I want to format the display of groupLabel according to its data type. if it is Long datetime value then I want to use dateformatter to change it to MM/DD/YYYY format. But in the first argument (i.e. item:Object), the GroupLabel property has text type of data. So I am usable to detect its data type.
I am using dummy column to show grouping information. So the second argument of GroupLabelfunction( i.e. col:AdvancedDataGridColumn) has no datafield and header text.
Please help me how can I accomplish my work
Thanks
sachindevtripathi@gmail.com
May 15, 2008 at 2:29 am
Sameer,
I have a question not directly related to this post, other than it is based on the AdvancedDataGrid. I overrode dragDropHandler(event:DragEvent)
and in this method, I would like to get the column where the drop occurred. I can get the row using calculateDropIndex(event), but I cannot figure out how to get what column this is dropped into. Any idea how to do this? Thanks.
Jay