Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

flexÎļþÏÂÔØ

1flex¶Ë
<mx:Button label="ÏÂ ÔØ" click="download()"/>
//ÏÂÔØ
  public function download():void{
   var str:String=this.uploadfiles.selectedIndex.toString();
   if(str=="-1"){
    Alert.show("ÇëÑ¡ÖÐÒªÏÂÔØµÄÎļþ");
   }else{
    downloadfiles();
   }
  }
  public function downloadfiles():void{
   var loadid:String=this.uploadfiles.selectedItem.loadid;
   if(loadid==null || loadid==""){
      Alert.show("¶Ô²»Æð£¬¸ÃÎļþ»¹Î´ÉÏ´«");
      }    
      var urlAddress:String=model.root+"/uploadFiles.do?method=download&loadid="+loadid;   
      //URLRequest¿ÉÒÔ²¶»ñµ¥¸öHTTPµÄËùÓÐÐÅÏ¢
      var url:URLRequest=new URLRequest(urlAddress);
         var loadname:String=this.uploadfiles.selectedItem.loadname;
         //download()·½·¨ÌáʾÓû§ÌṩÎļþµÄ±£´æÎ»Öò¢¿ªÊ¼´ÓÔ¶³Ì URL ½øÐÐÏÂÔØ¡£
         filedown.download(url,loadname);
  }
  protected override  function createChildren():void{
   super.createChildren();
   filedown.addEventListener(Event.COMPLETE,onDownCompleted);
  }
  public  function  onDownCompleted(evt:Event):void{
     this.resultlabel.visible=true;
        var fileref:FileReference = evt.currentTarget as FileReference;
        resultlabel.text = "ÎļþÃû:" + uploadfiles.selectedItem.loadname+ "ÏÂÔØÍê±Ï£¡";     
  }
javaºǫ́(action)
 /**
  * ÎļþÏÂÔØ
  *
  * @param mapping
&nb


Ïà¹ØÎĵµ£º

flex datagrid ¶à¸öµ¥Ñ¡°´Å¥

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" creationComplete="init()" layout="absolute" xmlns:ns1="com.component.*">
<mx:Script>
 <![CDATA[
  import com.component.DataHBox;
  import com.component. ......

Flex DataGridäÖȾͼƬ

³õѧflex£¬Óöµ½Ò»¸öÎÊÌâ‘ÔÚdatagridµÄÒ»ÁÐÖÐÀûÓÃËüµÄֵת»»ÏÔʾ²»Í¬µÄͼƬ’£¬ÔÚÍøÉÏËÑÁËËÑÎÊÁËÎÊ£¬½â¾öÁ˰¥,½â¾ö°ì·¨Ìù³öÀ´£¬Ï£Íû¶ÔÆäËûÈËÓаïÖú£¬
ÀûÓÃdatagridµÄlabelFunction½â¾öµÄ£¬ÈçÏ£º
ÔÚdatagridµÄ
<mx:DataGridColumn  dataField="level"  labelFunction="formatiImg"/>
/* ......

Flex Framework Fundamentals

ת×Ô£ºhttp://www.cnblogs.com/sharplife/archive/2007/09/03/880641.html
×î½ü¿´Ê±Ñ§Ï°FlexÓ¦Ó㬿ªÊ¼¶ÔFlexºÍFlashµÄ¹ØÏµÓÐЩģºý£¬¶ÁÁËOreillyµÄProgramming Flex
2²ÅËãÊÇÃ÷°×Щ£¬ÏÖ¼ÇÏ¡£
1¡¢FlexÓ¦ÓóÌÐòµÄÉúÃüÖÜÆÚ
FlexÓ¦ÓÃ¾ÍÆä¸ù±¾ÉϽ²¾ÍÊÇFlashÓ¦Óã¬Ö»²»¹ýÆäÊÇ»ùÓÚFlex
Framework£¨ÓÉActionScriptд¾Í£©¿ª· ......

flexͨ¹ýHTTPService×é¼þ¶ÁÈ¡¸´ÔӽṹµÄxmlÎļþ

    ŪÁËÁ½Ì죬ÖÕÓڰѸ´ÔÓµÄxmlÎļþµÄÊý¾Ý¸ù¾Ý×Ô¼ºµÄÒªÇó¶Á³öÀ´£¬ÏÔʾÔÚÒ³ÃæÉÏÁË¡£flexͨ¹ýHTTPService×é¼þ·¢ËÍÇëÇ󣬶ÁÈ¡xmlÎļþÖÐÊý¾Ý£¬ÓÃxmllistcollection´æ´¢xmlÖÐijһ²¿·ÖÊý¾Ý£¬²¢°ó¶¨ÔÚgridview¿Ø¼þÉÏ¡£
    xml£¬xmllist£¬xmllistcollectionÖÐÖ»ÓÐxmllistcollection¾ßÓÐÐ޸ĸüÐÂÊý¾ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ