Setting size of paper during print

Hi
I have two printers attached to the system, one is the regular printer and the other is a barcode printer. I changed the default setting of the barcode printer through windows, and I am calling the print dialog through my java code. When I select the barcode printer through the print dialog and hit the properties button, it shows me a different setting than the one I setted through start ->setting ->controlPanel->printer
Is there a way to get the same setting in the print dialog.
Could any one please help
Thanks

   PrinterJob printJob = PrinterJob.getPrinterJob();
   PageFormat printPageFormat = printJob.defaultPage();
   Paper printPaper = printPageFormat.getPaper();
   Rectangle printArea = printPaper.getImageableArea();should give for example a [28, 28, 538, 785] rectangle, which takes into account the paper margins.
Hope this helped,
Regards.

Similar Messages

  • Is it possible to use an AppleScript to set a *custom* paper size in Word?

    I've used the following script to set the paper size in Word:
    tell application "Microsoft Word"
              set paper size of page setup of section 1 of active document to paper a4
    end tell
    but I've been unable to write a script to set a custom paper size -- does anyone know if this is possible?
    Thanks!

    The gallant Pierre strikes again!!!  For reasons having to do with a quirk of working with Word documents coming from a Windows machine, I ended up having to go the UI route, but I couldn't have done it without you!  I actually ended up changing the Format For: popup menu instead of the Paper Size: popup menu, but this technique could be used for those who wish to chose a custom paper size:
    tell application "Microsoft Word"
      activate
    end tell
    tell application "System Events"
              delay 0.5
      keystroke "a" using command down
              tell application process "Microsoft Word"
                        click menu item "Page Setup..." of menu "File" of menu bar item "File" of menu bar 1
      delay 1
      click pop up button 3 of window "Page Setup"
      keystroke "Any"
                        delay 0.5
      keystroke return
                        delay 0.5
      keystroke return
      delay 1
                        click menu item "Print..." of menu "File" of menu bar item "File" of menu bar 1
      delay 1
                        tell menu button "PDF" of window "Print"
      click
                                  click menu item "Create Booklet" of menu 1
                        end tell
              end tell
    end tell
    Again, Pierre -- many thanks!
    Andrew

  • Canon Pixma Pro-100 printer ejects 3.8 in of a 4X6 paper and prints only 2.2 in of the image printing from Photoshop CS6, I'm sure I set everything correctly - what could I be missing?

    Using Mac Pro running Snow Leopard (10.6.8) & editing & printing from Photoshop CS 6.
    Have new Canon Pixma Pro-100 printer and set it up yesterday.  First thing printed was a
    document from MS Word (a letter) 8.5 X 11 plain paper - this came out OK.  Next I fire up
    Photoshop and open a 4 X 6 inch image to do a test print.  I set it up in the print dialog as
    4X6 paper, Canon's Pro Glossy paper profile, rear tray, standard print quality, Photoshop
    manages the color.  I load the paper in the rear tray close the covers and hit print.  Now, when
    it starts to print the printer moves about 3.8 inches of paper out of the printer and starts printing
    on the remaining 2.2 inches then spits the paper out.  It does this in Photoshop (any image it doesn't
    matter), and it does it printing from Capture NX.  I have been able to get it to print on the paper
    correctly using Apple's Preview program but that that's not going to do me any good.  I was on
    the phone with Canon tech support for about 2 hours and they were completely puzzled suggesting
    I would have to use Canon's printing apps instead to print - that doesn't do me any good either.
    I want to be able to print from Photoshop.  Any one every heard of this or experienced the same
    problem? Thanks JamesD!

    Hello again. I recognize that a print is good if you like it and bad if you don't, despite what others might say, but I will at least share my experiences. They might help you or others who are following this thread.
    My monitor is calibrated with Spyder 3. Gamma 2.2, 6500K, 83 cd/m^2. Contrast at 50%; brightness about 52%. My monitor lets me choose blackness level - it defaults to 50%.
    When I print the test image I linked to above, using Lightroom, with no adjustments, my technical output is as follows:
    Middle step wedge shows twelve disticnt steps. Whitest step is color of unprinted paper.
    It varies from paper to paper, but I can discerne at least the 252 step and on some papers 253 - telling me I have good highlight detail.
    On the black side I discerne 8 or 10, nothing lower. (That sounds like what you are reporting).
    Artistically I am very happy how my print looks - nice red strawberries, good flesh tones, etc.
    One my monitor, the on-screen image is almost identical to the print. I am surprised that you can see the 2 wedge step on screen at a very similar brightness.
    I also checked out this B&W test image:
    http://www.northlight-images.co.uk/article_pages/bw_printing/bw-test-image-2.html
    You are probably aware of this since you are printing with Print Studio Pro, but others may not be.
    You can print a series of test images:
    find the one that best suits your taste, enter the calibration values in PSP, and save them as a custom setting. Then, each time you want to print recall the setting.
    You can do a similar thing in Lightroom using the printer driver and User Templates.
    There would be some one-time trial and error to that approach.
    John Hoffman
    Conway, NH
    1D Mark IV, Rebel T5i, Pixma PRO-100, MX472

  • Ever since the up dates... Any of my photos that I use and want to set as wall paper... The software blows the picture out of portion and no way of cropping it and keeping it at the regular size!!!! How can this be fixed!!

    Ever since the up dates... Any of my photos that I use and want to set as wall paper... The software blows the picture out of portion and no way of cropping it and keeping it at the regular size!!!! How can this be fixed!!???

    Hope this helps:
    http://ios.wonderhowto.com/how-to/fixing-ios-7-wallpaper-woes-scale-crop-align-d esign-perfect-iphone-background-0148750/
    Please reply with any further questions.

  • HT5137 i tried using the setting icon to reset the prints and icon to a bigger size, thereafter the setting icon lost colore to gray and stopped responding

    i tried using the setting icon to reset the prints and icon to a bigger size, thereafter the setting icon lost color to gray and stopped responding.? most of the pop up boxes will also not respond why?

    Thanks Winston, restarting my router worked for me too. Seems that somehow the DCHP (maybe due to the Mountain Lion upgrade?) had assigned the same IP address to both the AppleTV and my iMac. The AppleTV stopped appearing as an AirPlay device for my iPhone and Mac, but still the AppleTV had Internet access.
    Restarting the router reassigned IPs and without fanfare, the AppleTV is now available to AirPlay.

  • Small size (A6) paper printing and toner leak(pouring out) issue

    We have recently purchased 15 pieces of Hp LaserJet P1102w.
    We are printing reciepts of size A6 (1/4 of A4). The use of printers are quite heavy - 200 A6 pages per day.(And no other formats)
    After a month of usage we are expiriencing a huge problem. (Now it has been 5 printers in period of 3 weeks):
    In Some random printers the toner is pouring out. First inside of the printer and then on the table (there is a convinient opening at the bottom). This happens on one side of the cartridge. And the affected drum is heavily dirty on that side.
    We checked all kind of possible causes:
    The retailer pointed us to this link, that states: "
    HP does not recommend printing large quantities of small or narrow paper. Printing large quantities of small or narrow paper can cause toner to leak from the print cartridge and damage the printer or cause print-quality problems."
    but this is for HP LaserJet 4200, 4300 Series Printers
    http://webcache.googleusercontent.com/search?q=cache:vGQOfpKgjmUJ:h20564.www2.hp.com/portal/site/hps...
    My question is: is it true that heavy printing of small paper size can cause this problem? And how probable is it?
    What else could have caused this?
    Thank You

    Hi agniss,
    I just sent you a private message.
    If you are not sure how to check your post forum messages, this has instructions.
    Thank You.
    Please click “Accept as Solution ” if you feel my post solved your issue, it will help others find the solution.
    Click the “Kudos Thumbs Up" on the right to say “Thanks” for helping!
    Gemini02
    I work on behalf of HP

  • Setting JTextPane size so that it prints at 2" x 3.5"

    I need to set the size of a JTextPane in a way that it will always be printed as 2" x 3.5", no matter what the resolution or the screen size may be.
    I have tried setting the size in pixels, using the following formula: pixels = inches x DPI
    This doesn't always work however (ex: when Windows Vista settings are set to larger scale (120DPI), the JTextPane prints larger than desired).
    This is the code:
    // set sizes
            int screenResolutionDPI = Toolkit.getDefaultToolkit().getScreenResolution();
            int widthInches = 2;
            int heightInches = 3.5;
            cardWidth = (int) (widthInches * screenResolutionDPI));
            cardHeight = (int) (heightInches * screenResolutionDPI));
            setPreferredSize(new Dimension(cardWidth, cardHeight));
            setMinimumSize(new Dimension(cardWidth, cardHeight));
            setMaximumSize(new Dimension(cardWidth, cardHeight));
            setSize(new Dimension(cardWidth, cardHeight));Any help on this would be much appreciated.
    Thanks!

    That works. Glad to see it's that simple.
    Here is the working code:
    // set sizes
            int widthInches = 2;
            double heightInches = 3.5;
            cardWidth = (int) (widthInches * 72);
            cardHeight = (int) (heightInches * 72);Thanks for your help!

  • Printer setting for teslin paper

    Hi
    I printed on some normal paper and then some teslin paper
    The quality of the print on teslin paper was not as grate to that of standard paper
    And also little chunks of print where missing on the teslin paper
    In the 'page setup' options for 'properties' there is a drop down box called 'media type' and its set to 'plain paper' as default
    There are quite a few options from the drop down box one of them called 'glossy photo paper'
    I dont want to print on them all (all of the options) as I dont have a lot of teslin paper
    Can someone advice on the best option please
    Thanks
    Batista230

    Hi Batista230,
    I've printed on Teslin® Substrate before and I've had no issues. Please let me help you with this.
    May I know what type of printer are you using? (i.e. inkjet, laser etc.)
    Also, I heard that some ppl out there are selling substandard materials of Teslin. Any possibility that you obtained not the good grade?
    Cheers.
    Pat

  • Image cropped during printing!

    Hello,
    I have a tiff image that is 13 x 48 inches @ 300 dpi, that keeps getting cropped to 8 x 11 inches during printing. I do not understand what is happening.
    I have an Epson Stylus Photo 1400 printer. I set my paper size in the "manage custom sizes" dialogue box, double and triple check all of my settings, previews and every maddening, minute detail, but it keeps cropping my images and I have wasted a plethora of ink and beautiful handmade paper.
    I have done everything imaginable to try and remedy this problem. I have updated my printer driver, researched forums, spoke to support, had my friends look at my Photoshop settings, gone through every setting and tool and nothing is working.
    I can't help but think it is something so painfully obvious and simple. Any ideas? Could it be my screen resolution, some obscure setting in Photoshop?
    Thank-you for any ideas...

    What is the size of your paper?  What are the pixel dimensions of the file?  How much RAM and how much available disk space do you have?
    What exact version of Photoshop are you running, 12.0.2?  What exact version of the OS, 10.6.7 ?
    Have you downloaded and installed the latest version of the Epson driver for your printer?
    Can you post a screen shot of what the print dialog box looks like in Photoshop?
    Wo Tai Lao Le
    我太老了

  • Is it possible to Default "Choose page source by PDF page size" option in the "Print" dialog box?

    I have an SSRS report that is rendered as a PDF file; the report has many columns and utilizes 11inx17in (Landscape) paper. However, once the report is rendered and users try to print the report they have to manually select the 'Choose Paper source by PDF page size' option in order to get the report to print on the correct paper (otherwise it defaults to standard letter size - landscape orientation).
    I'm aware of 'Print Presets' functionality; however, I don't believe they apply to this scenario. Is there a config file/registry setting/anything that can be specified to automatically set the 'Choose paper source by PDF page size' print setting = On/True/Checked?
    Any help would be greatly appreciated...

    Anybody out there?

  • How do I set up a booklet to print with my Konica Minolta?

    how do I set up a booklet to print with my Konica Minolta?

    Is it a BizHub? If so, use the booklet printing from the Koncia driver.
    If it's like the one I have, click the Printer button at the bottom of InDesign's print dialog, then choose Layout/Finish from the drop down menu, and booklet from there.
    One thing to note: with this method, leave your paper size the same as one page of your document.

  • Document Size v Paper Size

    I am using Acrobat Pro 8 with a HP 3050 all in one. I am attempting to print two forms I created from scanned images (that have form fields) that are irregular sizes. I am only printing the form fields and not the scanned image, so my print setting is set to "form fields only".  However, my form fields are not aligning with the documents I am feeding through the printer and I've noticed that there is a "document" size and "paper" size of two different sizes in the printer dialog box and have no idea why.
    For example, at the bottom right of the print dialog box, the paper size says 7.0" x 3.4" (the correct/actual size) but the document size is saying 7.5 x 3.9 (not sure where this size is coming from). When I use the rulers to measure it in Acrobat, it says 7.0" x 3.4", yet when I print it out, the text is out of alignment and treating the document as if it is 7.5 x 3.9. The same thing happens with another document that I'm attemping to do the same thing with.  In the print dialog box, the document size is saying 5.5" x 3.1" and the paper size is saying 5.8 x 3.9.
    Is there any way to over ride or change this? I suspect it's somehow due to the HP print driver.  If there's an alternative to accomplish what I'm doing, I'm open to any suggestions. I am using preprinted forms that I'd like to have fed in the printer. I don't necessarily want to re-create them in InDesign or Illustrator (I originally scanned the forms using Acrobat).
    Thank you.

    @Bill@VT - Sorry, that didn't work with either form I'm using. It is not allowing me to enter a custom size. It is
    defaulting to a 8x13 (custom) size.

  • Hiding the layout during printing

    Hi Experts,
    Is there any way to hide the layout during printing? I have developed a PDF form with complex layout. I want our Customers view the form in print preview and see that all the values are correctly aligned within the boxes before printing. But they print this form on a pre-printed paper (which already has the layout) so I want to make sure that only fields which are binded to a data item are printed and not the layout and static texts. Is this possible?
    Regards,
    Srini.

    Hi,
    Try this code:
    <object>.presence = "visible"; //this makes the object visible in the form
    <object>.relevant = "-print";    //this object will not be printed
    The relevant property indicates whether an object should appear when the form is printed.
    &#9679; +print (default for visible objects)
    Forces a particular object to appear when the form is printed,
    regardless of the object’s presence property setting.
    &#9679; -print (default for invisible or hidden objects)
    Forces an object not to appear when the form is printed,
    regardless of the object’s presence property setting.
    Regards
    Srikanth

  • Error message Load paper in printer when I print a certain word document

    HP Officejet Pro 8500A on Windows Vista-32 bit
    Printer works great apart from when I try and print one word document or any other word document based on it
    I press print,printer tells me it's printing then I get the error message. "load paper in printer" when there is plenty of paer in it
    Other word documents and previous printer was OK
    Thanks

    Hi,
    As the issue occours with a specific document only, make sure to verify that any of the document settings are set correctly
    (e.g. the right paper size, the page margins, etc...)
    Additionaly, try copying the entire content of the document and paste into a new blank document, try printing the new document and check for any change.
    Say thanks by clicking the Kudos thumb up in the post.
    If my post resolve your problem please mark it as an Accepted Solution

  • How do i set the default paper tray to tray 2 on hp color laserjet 5225dn

    I do not see the setting for tray behavior in the control panel

    Okay the printer that I have access to is set to these settings:
    Control panel - system setup - paper setup
     Then you should have these options:
    There is a default paper type screen but I don't have a screen shot of that one.
     Same for tray 1.
    You will  have them for each tray (tray 1, Tray 2, Tray 3)
    My tray settings are:
    Tray 1 - paper size = any, paper type =  any
    Tray 2 -  same as tray 1
    Tray 3 is set as:
    Does this help?
    I am an HP employee.
    Say Thanks by clicking the Kudos Star in the post that helped you.
    Please mark the post that solves your problem as Accepted Solution

Maybe you are looking for