Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Make view between print dialogue and run printOperation?

Make view between print dialogue and run printOperation?
Thread Tools
Professional Poster
Join Date: Sep 1999
Location: Ottawa, ON, Canada
Status: Offline
Reply With Quote
Mar 5, 2004, 07:04 PM
 
I asked something similar yesterday but I don't think I worded it correctly.

I have an accessoryPanel in my printPanel that asks to print All Records or Needed Records (needed is defined in the data). Unfortunately, in order to raise the print dialogue you have to make an NSPrintOperation and supply it the view before it even raises the dialogue. How do I know what to put in the view if the user hasn't selected the data yet?

In orther words, is there a way to raise the dialogue, then if the user clicks Print or Preview, then create the view and pass it to the print operation and run it?
     
Clinically Insane
Join Date: Oct 2001
Location: San Diego, CA, USA
Status: Offline
Reply With Quote
Mar 5, 2004, 08:59 PM
 
I think you're just supposed to customize the view you have. Otherwise I guess you could try subclassing.
Chuck
___
"Instead of either 'multi-talented' or 'multitalented' use 'bisexual'."
     
hayesk  (op)
Professional Poster
Join Date: Sep 1999
Location: Ottawa, ON, Canada
Status: Offline
Reply With Quote
Mar 6, 2004, 11:57 AM
 
Originally posted by Chuckit:
I think you're just supposed to customize the view you have. Otherwise I guess you could try subclassing.
The view is subclassed - but that doesn't allow me to tell the print dialogue to change it between clicking print and actually printing.
     
Clinically Insane
Join Date: Oct 2001
Location: San Diego, CA, USA
Status: Offline
Reply With Quote
Mar 6, 2004, 02:14 PM
 
Sorry, wasn't clear. I didn't mean subclassing the view -- I meant subclassing the print panel and/or print operation.
Chuck
___
"Instead of either 'multi-talented' or 'multitalented' use 'bisexual'."
     
hayesk  (op)
Professional Poster
Join Date: Sep 1999
Location: Ottawa, ON, Canada
Status: Offline
Reply With Quote
Mar 6, 2004, 04:10 PM
 
Originally posted by Chuckit:
Sorry, wasn't clear. I didn't mean subclassing the view -- I meant subclassing the print panel and/or print operation.
Ah, sorry, I see what you meant now. I actually didn't have to go that far. I basically made a tiny view and passed it to the printOp. When the printOp asked for the page range, I initialized my data to be printed (based on the values in my accessory panel) and expanded the view to accomodate the new data.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 09:00 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2