Adobe Dreamweaver Forums



Last 10 THreads :         Snippet Pod Problems (Last Post : Pat@ffic - Replies : 0 - Views : 1 )           »          CFGRID, please help (Last Post : The ScareCrow - Replies : 1 - Views : 2 )           »          How can I make an image to stay at the bottom of abrowser? (Last Post : Greg Lafrance - Replies : 1 - Views : 2 )           »          Change custom Vector class to new Vector class in player10 (Last Post : flexstone - Replies : 0 - Views : 1 )           »          Need help with image slide show using xml (Last Post : shariha - Replies : 0 - Views : 1 )           »          Array with For Loop Basics (Last Post : MediaMackenzie.com - Replies : 6 - Views : 7 )           »          FW CS3 doesn't work with new scanner (Last Post : SonoranSites - Replies : 0 - Views : 1 )           »          Array of Queries (Last Post : Ian Skinner - Replies : 2 - Views : 3 )           »          Confirmation email entered twice and identical (Last Post : Baxter - Replies : 1 - Views : 2 )           »          Not Recognizing XML File (Last Post : andrewmcgibbon - Replies : 1 - Views : 2 )           »         


User Info Statistics
Go Back   Adobe Dreamweaver Forums > Macromedia Software > Flex
 
Tags:



Reply
  #1 (permalink)  
Old 11-05-2008, 08:43 AM
black_zoro143
 
Posts: n/a
Diggs:
Default saving capture image into folder

Hello!
i want to save the snapshopt capture image into folder, i found that code
but its only capture image but don't know how to save it to a specific dir.
waiting for your help please

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
layout="vertical"
verticalAlign="middle"
backgroundColor="white">

<mx:Script>
<![CDATA[
import mx.core.IUIComponent;
import mx.graphics.ImageSnapshot;

private function takeSnapshot(source:IBitmapDrawable):void {
var imageSnap:ImageSnapshot =
ImageSnapshot.captureImage(source);
var imageByteArray:ByteArray = imageSnap.data as ByteArray;

swfLoader.load(imageByteArray);
}
]]>
</mx:Script>

<mx:Array id="arr">
<mx:Object col1="Row 1, Col 1" col2="Row 1, Col 2" />
<mx:Object col1="Row 2, Col 1" col2="Row 2, Col 2" />
<mx:Object col1="Row 3, Col 1" col2="Row 3, Col 2" />
<mx:Object col1="Row 4, Col 1" col2="Row 4, Col 2" />
<mx:Object col1="Row 5, Col 1" col2="Row 5, Col 2" />
<mx:Object col1="Row 6, Col 1" col2="Row 6, Col 2" />
</mx:Array>

<mx:ApplicationControlBar dock="true">
<mx:Button label="Take snapshot of DataGrid"
click="takeSnapshot(dataGrid);" />
</mx:ApplicationControlBar>

<mx:HBox>
<mxataGrid id="dataGrid" dataProvider="{arr}" />

<mx:SWFLoader id="swfLoader">
<mx:filters>
<mxropShadowFilter />
</mx:filters>
</mx:SWFLoader>
</mx:HBox>



Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 11-05-2008, 09:32 AM
dietmar.paulus
 
Posts: n/a
Diggs:
Default Re: saving capture image into folder

Hey

if you use Flex not AIR, with FlashPlayer 9 you can't save the ImageSnapshot
to the HDD, with FlashPlayer 10 you can save data with the FileReference class
(there's a save() Method), but only with user interaction.

Cheers

Dietmar Paulus

Reply With Quote
  #3 (permalink)  
Old 11-05-2008, 10:03 AM
black_zoro143
 
Posts: n/a
Diggs:
Default Re: saving capture image into folder

thank you so much,
can you please tell me can't i even save image on server directory, its online application, so i want to take screenshot and want to save it on web directory.
Reply With Quote


  #4 (permalink)  
Old 11-05-2008, 10:53 AM
black_zoro143
 
Posts: n/a
Diggs:
Default Re: saving capture image into folder

i import flex sdk 4.XXXX version and flash player 10 also
but it is giving me error
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



© Camley Interactive (camley.info) 2008 - all logos and images are copywrite their respective owners.
Proud member of the Camley Interactive Network
All times are GMT. The time now is 10:24 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
Cheap Car Insurance - Compare Motor Insurance
Endsleigh Car Insurance Natwest Car Insurance
More Than Car Insurance Norwich Union Car Insurance
Prudential Car Insurance Zurich Car Insurance
Inactive Reminders By Mished.co.uk