Toggling file extensions on the FileSystemDataGrid control in Adobe AIR

by Peter deHaan on December 19, 2008 · 0 comments

in FileSystemDataGrid

In a previous example, “Toggling file extensions on the FileSystemTree control in Adobe AIR”, we saw how to toggle file name extensions on the Adobe AIR FileSystemTree control by setting the showExtensions property.

The following example shows how you can toggle file name extensions on the Adobe AIR FileSystemDataGrid control by setting the showExtensions property.

Full code after the jump.

<?xml version="1.0" encoding="utf-8"?>
<!-- http://airexamples.com/2008/12/19/toggling-file-extensions-on-the-filesystemdatagrid-control-in-adobe-air/ -->
<mx:WindowedApplication name="FileSystemDataGrid_showExtensions_test"
        xmlns:mx="http://www.adobe.com/2006/mxml"
        layout="vertical"
        verticalAlign="middle"
        backgroundColor="white"
        status="{dataGrid.directory.nativePath}">
 
    <mx:ApplicationControlBar dock="true">
        <mx:Form styleName="plain">
            <mx:FormItem label="showExtensions:">
                <mx:CheckBox id="checkBox" selected="true" />
            </mx:FormItem>
        </mx:Form>
    </mx:ApplicationControlBar>
 
    <mx:FileSystemDataGrid id="dataGrid"
            showExtensions="{checkBox.selected}"
            width="100%"
            height="100%" />
 
</mx:WindowedApplication>

{ 0 comments… add one now }

Leave a Comment

You can use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="">

Previous post:

Next post: