Regarding Adobe Flex: Export As A PNG Image - Article by Srirangan
DiggBlinkRedditDeliciousTechnorati
question by suneeth | Moderate
below is a code snippet from the article by Srirangan..
--------------------------------------------------------------------------------
public function downloadChart():void
{
var bd:BitmapData = new BitmapData(OBJECT_ID.width, OBJECT_ID.height);
bd.draw(OBJECT_ID);
var png:ByteArray = encode( bd );
var variables:URLVariables = new URLVariables();
variables.uid = "156";
variables.item_name = "Chart";
var request:URLRequest = new URLRequest( "DownloadImage.php" );
request.data = png;
request.method = URLRequestMethod.POST;
navigateToURL( request );
}
--------------------------------------------------------------------------------
Problem -
I am not able to compile the action script class..
Questions -
what is OBJECT_ID ?
where is the method, navigateToURL (request) ?
Can somebody also explain variables.uid and variables.item_name?
Thanks in advance.
Post reply
Subscriptions
Re: Regarding Adobe Flex: Export As A PNG Image - Article by Sriranganreply by Srirangan Suneeth,
Replace OBJECT_ID with the Id of the Flex object that you want to export in the Png.
Rgds,
Sri
Post reply
Subscriptions
Got a Adobe Flex Question?
Just Sign Up and ask the top Adobe Flex experts!
|