0 Replies Latest reply on Mar 9, 2007 3:45 PM by emails.myjunk@gmail.

    Problem with Eclipse and ActionScript

    emails.myjunk@gmail.
      I'm working with an example from the book "Adobe Flex 2: Training from the Source". In that book, there is an example that has the following code:
      quote:


      <?xml version="1.0" encoding="utf-8"?>
      <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml" layout="horizontal">
      <mx:Model id="prodModel">
      <groceries>
      <catName>Dairy</catName>
      <prodName>Milk</prodName>
      <imageName>assets/dairy_milk.jpg</imageName>
      <cost>1.20</cost>
      <listPrice>1.99</listPrice>
      <isOrganic>true</isOrganic>
      <isLowFat>true</isLowFat>
      <description>Direct from California where cows are happiest!</description>
      </groceries>
      </mx:Model>
      <mx:Script>
      <![CDATA[
      import flash.net.filereference;
      public function fileBrowse():void{
      var myfileref:FileReferenceList = new FileReferenceList();
      myfileref.browse();
      }
      ]]>
      </mx:Script>

      <mx:Form x="115" y="10" width="75%" height="75%">
      <mx:FormHeading label="{prodModel.catName}" />
      <mx:FormItem label="ProductNameUnit" direction="horizontal">
      <mx:ComboBox/>
      <mx:TextInput/>
      </mx:FormItem>
      <mx:FormItem label="Cost">
      <mx:TextInput id="cost" text="{prodModel.cost}"/>
      </mx:FormItem>
      <mx:FormItem label="List Price">
      <mx:TextInput id="listPrice" text="{prodModel.listPrice}"/>
      </mx:FormItem>
      <mx:FormItem label="Description">
      <mx:TextInput id="Description" text="{prodModel.description}"/>
      </mx:FormItem>
      <mx:FormItem label="Image Path">
      <mx:TextInput id="imageName" text="{prodModel.imageName}"/>
      <mx:Button label="Browse" click="fileBrowse()"/>
      </mx:FormItem>
      <mx:FormItem>
      <mx:HBox>
      <mx:Button label="Update"/>
      <mx:Button label="Delete"/>
      </mx:HBox>
      </mx:FormItem>
      </mx:Form>
      </mx:Application>





      In eclipse, it gives an error saying that "Definition flash.net.filereference could not be found".

      Any ideas as to what I am missing.

      Thanks,
      Mahesh