2 Replies Latest reply on Apr 3, 2012 7:26 AM by Zolotoj

    Documentation question

    Zolotoj Level 3

      Use the Flex tasks in Ant:

      1. Add a new taskdef task to your project. In this task, specify the flexTasks.tasks file as the resource, and point to the flexTasks.jar file for the classpath. For example:<taskdef resource="flexTasks.tasks" classpath="${basedir}/flexTasks/lib/flexTasks.jar"/>
      2. Define the FLEX_HOME and APP_ROOT properties. Use these properties to point to your Flex SDK’s root directory and application's root directory. Although not required, creating properties for these directories is a common practice because you will probably use them several times in your Ant tasks. For example:
        <property name="FLEX_HOME" value="C:/flex/sdk"/> <property name="APP_ROOT" value="myApps"/>
      3. Write a target that uses the Flex Ant tasks. The following example defines the main target that uses the mxmlc task to compile the Main.mxml file:
        <target name="main"> <mxmlc file="${APP_ROOT}/Main.mxml" keep-generated-actionscript="true"> <load-config filename="${FLEX_HOME}/frameworks/flex-config.xml"/> <source-path path-element="${FLEX_HOME}/frameworks"/> </mxmlc> </target>

      where exactly am I doing this? For example, Add a new taskdef task to your project

       

      Thanks