Hi,

Following is my personal opinion not Macromedia's :)

>Also in hopes someone has solved this!
Yeah, someone has to solve it..., either MM or you guys...

As a developer myself I feel that components/controls can(should) never be
100% intelligent for printing purpose. It's  would not be a good idea to
bloat a components code with printing logic because not all users want to
print stuff or everyone has a different requirement. However a mechanism
which allows extensibility of components is more important. Like in this
case, you can have a print view, which gets printed instead of actual view.

-abdul



-----Original Message-----
From: Tracy Spratt [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 08, 2005 12:12 AM
To: [email protected]
Subject: RE: [flexcoders] Re: PrintJob()


To be clearer, despite several attempted examples (specifically the
TechNote: "Flex 1.0: Sample code for printing from a DataGrid"), there
is no way to get an entire scrollable area to print on a single page.
Your example does not test this since the content fits within the
control being printed.  I mentioned this since in a Help system, it is
reasonable to expect that there may be topics longer than will fit
within a single display control's visible area.

Also in hopes someone has solved this!

Tracy

-----Original Message-----
From: Abdul Qabiz [mailto:[EMAIL PROTECTED] 
Sent: Thursday, April 07, 2005 4:00 AM
To: [email protected]
Subject: RE: [flexcoders] Re: PrintJob()


Is it in  my mails response?

-abdul 

-----Original Message-----
From: Tracy Spratt [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, April 06, 2005 11:25 PM
To: [email protected]
Subject: RE: [flexcoders] Re: PrintJob()


Of course it will only print what is visible in the VBox...
Tracy

-----Original Message-----
From: Abdul Qabiz [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, April 06, 2005 5:15 AM
To: [email protected]
Subject: RE: [flexcoders] Re: PrintJob()

Hi Rich,

Try this....



##PrinJobExample.mxml###

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.macromedia.com/2003/mxml";
xmlns="*">

        <mx:Script>
                <![CDATA[
  
            import Help;
           
            var helpRef;
            
            public function testPrintJob():Void 
            {                   
                helpRef= createChild(Help, "help");

                        //wait untill help is created & rendered
completely...
                helpRef.addEventListener("creationComplete",
mx.utils.Delegate.create(this, printHelp));
             }
            
            function printHelp()
            {
                 var printJob:PrintJob= new PrintJob();
                 printJob.start();
                 printJob.addPage(helpRef);
                 
                 printJob.send();
                 delete printJob;
                 destroyChild(helpRef);
            }   
    ]]>
        </mx:Script>
        
        <mx:Button label="print" click="testPrintJob();"/>

</mx:Application>


##Help.mxml###

<mx:VBox xmlns:mx="http://www.macromedia.com/2003/mxml";>
    <mx:Label id="_lbl" text="Hello I am Help...."/>
    <mx:Button label="Button in Help..."/>
</mx:VBox>



Hope that helps...


-abdul

-----Original Message-----
From: Rich Tretola [mailto:[EMAIL PROTECTED] 
Sent: Friday, April 01, 2005 5:43 PM
To: [email protected]
Subject: [flexcoders] Re: PrintJob()


Does anyone have any ideas about this ?



On Mar 31, 2005 3:06 PM, Rich Tretola <[EMAIL PROTECTED]> wrote:
> I am trying to print an mlmx file at the same level as the one calling
> the printjob.  Here is my code:
> public function testPrintJob():Void {
>         var printJob:PrintJob = new PrintJob();
>         var help:Help = new Help();
>         mx.core.Application.alert("testProperty :" +
help.testProperty);
>         printJob.start();
>         printJob.addPage(0);
>         printJob.addPage("help");
>         printJob.send();
>         delete printJob;
> }
> 
> Help.mxml is the object being created in the 2nd lineof the method and
> it is being created correctly as I can read the properties of the file
> through an alert on the next line, bit I am only getting the 1st page
> which is using 0 as the object path (_root).  I have tried using help
> with and without the quotes and can never get it added as a page.
> Anyone have any ideas ?
> 
> Rich
>


 
Yahoo! Groups Links



 






 
Yahoo! Groups Links



 




 
Yahoo! Groups Links



 





 
Yahoo! Groups Links



 







 
Yahoo! Groups Links



 





 
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/
 



Reply via email to