1 Reply Latest reply on Feb 5, 2011 10:12 PM by Flex harUI

    UNC path and dataProvider,ItemRenderer,BitmapImage

    alamata

      hey,...

       

      here is my trouble,...

       

      i use a dataProvider

       

      dataProvider.addItem("assets/photo_" + i.toString() + ".jpg");

       

      and a itemRenderer, bitmapImage

       

                <s:ItemRenderer>
                          <local:TiledImage 
                              width="180" height="180"
                              left="12" top="16"
                              source="{data}"/>
                             <s:BitmapImage source="@Embed('assets/funda.png')"/>
                      </s:ItemRenderer>

       

      where TiledImage  is

      .

      .

      .

      .

                  public function set source(value:Object):void {
                      loader.source = value;
                  }
                 
                  private function updateSource():void {
                      // use a SWFLoader to download the bitmap data then push that into the BitmapImage
                      bitmapImage.source = loader.content;
                  }
              ]]>


          </fx:Script>


          <mx:SWFLoader id="loader" complete="updateSource()" width="0" height="0" />
          <s:BitmapImage id="bitmapImage" width="100%" height="100%" fillMode="repeat" />

       

       

       

      Everything is ok when i use

       

      dataProvider.addItem("assets/photo_" + i.toString() + ".jpg");

       

      but NOT ok with an unc path

       

      dataProvider.addItem("\\MachineName\SharedFolderName\ImageName.png");

       

      i have also trying this

       

      dataProvider.addItem("//MachineName/SharedFolderName/ImageName.png");

       

      but without succes,...

       

      i believe that UNC PAtH can be loaded by a typical loader and URLrequest to resolve the path

       

      but i need the swfloader for using non embedded images in a spark bitmapImage

       

      have you  a solution to make that possible,...

       

      how can use UNC PATH in this case,...

       

      thanks for your comprehension,...