I'm tyring to add a datagrid to a sprite class that doesn't display
any data--its used strickly for printing. When I add the datagrid
to the sprite, the resulting printed output is just a blank page.
Can someone tell me what I'm doing wrong? My code is as follows:
private function loadData():void
{
for (var i:int=0; i<arrayOfData.length; i++)
{
var dg:DataGrid=new DataGrid();
var s:Sprite=new Sprite();
dg.dataProvider=arrayOfData[i];
dg.width=600;
dg.height=600;
s.addChild(dg);
s.height=600;
s.width=600;
arrayOfDGSprites[i]=s;
}
}
private function startPrinting():void{
var pj:PrintJob=new PrintJob();
var tempSprite:Sprite;
pj.start();
var i:int;
var scale:Number;
for (i=0; i<arrayOfDGSprites.length; i++){
tempSprite=Sprite(arrayOfDGSprites[i]);
pj.addPage(tempSprite);
}
pj.send();
CursorManager.removeBusyCursor();
}
--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/