Posts Tagged ‘Actionscript’
- In: Actionscript | Advanced DataGrid | Flex
- 16 Comments
AdvancedDataGrid Performance Polls
Posted on: April 7, 2008
- In: Actionscript | Advanced DataGrid | Flex
- 12 Comments
Hello Advanced DataGrid users,
We have added a poll about AdvancedDataGrid’s performance. Please take part in the poll and help us identify the areas which needs improvement.
The poll is hosted at flexpearls
Thanks again.
In this sample, I’m using an Advanced DataGrid as an item renderer within another Advanced DataGrid. This type of configuration is very useful to give a master-detail view. This configuration can be customized more depending on any specific requirements.
Application Source, Renderer source
Thanks to Sreeni for coming up with this.
- In: Actionscript | Flex
- 16 Comments
When you set Object/Collection as a source for an AdvancedDataGrid to display the source in a Hierarchical manner, the AdvancedDataGrid.dataProvider will return an instance of IHierarchicalCollectionView because internally the source is used to construct a HierarchicalCollectionView which is returned via the dataProvider property.
What if, you want the original source from this IHierarchicalCollectionView. Well, there are some API’s for achieving this -
// First, get the HierarchicalData used to create the HierarchicalCollection
var hd:IHierarchicalData = IHierarchicalCollectionView(adg.dataProvider).source;
//From the HierarchicalData, get the source collection/object
var source:Object = hd.getRoot();
Here is a sample.
Source here.
- In: Actionscript | Flex
- 120 Comments
There is a post in Flex component Yahoo group on how to show a 3-state checkbox in an AdvancedDataGrid.
It has been implemented for the Flex Tree Control in the Flex cookbook.
I thought lets write a similar example for AdvancedDataGrid. I made some changes in the original sample and here it is; working for the AdvancedDataGrid control.
- In: Actionscript | Flex
- 16 Comments
This example shows how AdvancedDataGrid can be configured to show summary with the Group node.
Here, I’m using GroupingCollection to calculate the Summary with summaryPlacement being “group”. Then using groupLabelFunction in AdvancedDataGrid and returning the Group Node’s value plus the Summary value.
Source mxml is located here.
- In: Actionscript | Flex
- 13 Comments
The GroupLabel specified while creating a GroupingCollection can be accessed while displaying summaries in AdvancedDataGrid.
Although, accessing the GroupLabel in summary rows can be quite a tedious task but it can be very useful.
Here is a sample. In this sample, the Group name is displayed in the summary rows along with the value for the summary.
Source -
- In: Actionscript | Flex
- 68 Comments
Filtering of Hierarchical Data in AdvancedDataGrid is quite straight forward.
Assign the filter function to the ADG’s dataProvider and call refresh() -
// assign filter function to
//the AdvancedDataGrid's dataProvider
IHierarchicalCollectionView(
adg.dataProvider).filterFunction =
myFilterFunc;
// refresh the ADG's dataProvider
IHierarchicalCollectionView(
adg.dataProvider).refresh();
Here is a Sample
And the Source
- In: Actionscript | Flex
- 10 Comments
One of my team member had a query on how to embed a text file in a Flex Application. We searched the help files but in vain.
The text cannot be retrieved if we use the following (Instead it will be better if I say, we didn’t find a way to retrieve it
) -
[Embed(source="text.txt",mimeType="application/octet-stream")]
private var TextClass : Class;
Then I came across the way on how to do it (though I don’t remember the exact source).
I’m posting it here as it may be helpful to the other developers.
Here are the files -
TestingEmbeddedText.mxml
EmbeddedText.as
text.txt
Pythagoras Fractal
Posted on: August 23, 2007
- In: Actionscript | Flex | Fractals
- 1 Comment
