Tag Archives: showDataTips

Toggling data tip targets on a PieChart in Flex

In a previous example, “Toggling data tips on a PieChart in Flex”, we saw how you could toggle data tips on a Flex PieChart control by setting the showDataTips property.

The following example shows how you can toggle data tip targets on a Flex PieChart control by setting the showDataTipTargets style.

Full code after the jump.

Continue reading Toggling data tip targets on a PieChart in Flex

Sorting date columns in a DataGrid

Here’s an example of sorting a column of dates in a Flex DataGrid. The dates start out as Strings (such as “04/14/1980”) so you create a custom sortCompareFunction on that DataGrid column which converts the strings to dates so Flex will sort the dates in sequential order (as oppsed to string order). Hope that helps somebody out there.

I also created a little tooltip on the date column which shows the dates in a somewhat more readable form (“April 14 1980”) using the DataGridColumn object’s showDataTips and dataTipFunction properties.

Full code after the jump.

Continue reading Sorting date columns in a DataGrid

Downloading files in Flex using the FileReference class

OK, enough embedding examples, lets take a look at downloading files using Flash Player’s FileReference class (flash.net.FileReference). This example demonstrates a basic usage of the FileReference class within Flex, allowing users to download a file from the server. This example also shows how you can use data tips in the DataGrid control by setting the data grid column’s showDataTips property to true and specifying a value for the dataTipField column.

Full code after the jump.

Continue reading Downloading files in Flex using the FileReference class