Printing jtable - how to set margins

Hi everybody,
I used the method print() for jTable like
jTable1.print();I see the print dialog after invoking print method, I see margins there. I would like set up margins in source code. How can I do that? Thx for your help.

First, be sure you are in Rich Text mode. If you aren't then change that in the Format menu of TextEdit. You will see the ruler above the page:
You create margins, indents, etc. using the settings in the toolbar.
The T gadget sets the left margin. The downward pointing arrow on the far right sets the right margin. The other arrow gadgets set tabs and can be set for left and right tabs as well as decimal tabs. CTRL- or RIGHT-click on the tab gadget to set it.

Similar Messages

  • JTable how to set cell ediatble false

    - Can teach me JTable how to set cell ediatble false?
    - And I'm not so understand about following method and sentence...
    addRowSelectionInterval(int index0, int index1)
    Adds the rows from index0 to index1, inclusive, to the current selection.
    - Then what is toggle? What is the usage? How to use?
    - Then how to add one more row in the Jtable?

    - Can teach me JTable how to set cell ediatble false?check the method isCellEditable()
    Use DefaultTableModel
    - And I'm not so understand about following method and sentence...
    addRowSelectionInterval(int index0, int index1)
    Adds the rows from index0 to index1, inclusive, to the current selection.
    - Then what is toggle? What is the usage? How to use?
    - Then how to add one more row in the Jtable?[JTable API|http://java.sun.com/j2se/1.5.0/docs/api/javax/swing/JTable.html]

  • HTML report graph is cut, how I set margins?.

    Hello,
    I trying to get a report with diferent graphs. But I got the graph cut. It seems I could set lower margin th get the whole graph printed.
    Is it possible to fit?.
    Another thing, Could I remove the linke in footer page of temporal file?.
    Best Regards.
    Attachments:
    My Report3a.vi ‏38 KB
    lvtemporary_299139.pdf ‏163 KB

    Printing a web page has always been difficult, and not just in LabVIEW.  I'm no expert, but I think you have to actually reformat (or create a new page) for printing.  That's why most web sites have a "Print" button.
    Bill
    (Mid-Level minion.)
    My support system ensures that I don't look totally incompetent.
    Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.

  • Printing JTable how to?

    How do I print my jtable which is in a scroll pane? If anyone can point me to a how-to on using the java.awt.print api to do so, or whatever , I'd appreciate it. Thanks!

    You could try JFreeReport, a class library for printing reports from data in a JTable (TableModel):
    http://www.object-refinery.com/jfreereport/index.html
    Supports headers, footers, grouping, report functions, print preview, export to PDF and more. Complete source code is included subject to the GNU LGPL.
    Regards,
    Dave Gilbert
    www.object-refinery.com

  • Set margins when printing

    I have problems to set the margins for printing..
    I set margins in this way:
    when I start the printing process I do:
            PrinterJob job = PrinterJob.getPrinterJob();
            final Stamp canvas = new Stamp();
            job.setPrintable(canvas);
            MediaPrintableArea area = new MediaPrintableArea(10, 10, 170, 255, MediaPrintableArea.MM);
            HashPrintRequestAttributeSet aset = new HashPrintRequestAttributeSet();
            aset.add(area);
            if (job.printDialog()) { // chiede conferma definitiva
                try {
                    job.print(aset);
                } catch (PrinterException ex) {
                    Logger.getLogger(Stampa_Try_For_PreciseLocation.class.getName()).log(Level.SEVERE, null, ex);
            }in the canvas class I try to read the margins :
    public int print(Graphics g, PageFormat pageFormat, int pageIndex) {
            if (pageIndex >= 1) {
                return Printable.NO_SUCH_PAGE;
            Graphics2D g2 = (Graphics2D) g;
            g2.translate(pageFormat.getImageableX(), pageFormat.getImageableY());
            AffineTransform at = new AffineTransform();
            at.scale(pageFormat.getImageableWidth(), pageFormat.getImageableHeight());
            g2.transform(at);
            double pageWidth = pageFormat.getWidth();
            double pageHeight = pageFormat.getHeight();
            double pageSpUsedX = pageFormat.getImageableX();
            double pageSpUsedY = pageFormat.getImageableY();
            double pageSpUsedWidth = pageFormat.getImageableWidth();
            double pageSpUsedHeight = pageFormat.getImageableHeight();
            System.out.print("larghezza pg = " + pageWidth);
            System.out.println(" ; altezza pg = " + pageHeight);
            System.out.print ("area usabile X = " + pageSpUsedX);
            System.out.println(" ; area usabile Y = " + pageSpUsedY);
            System.out.print("area usabile larghezza  = " + pageSpUsedWidth);
            System.out.println("  ; area usabile altezza = " + pageSpUsedHeight);
            g2.drawString("x as", (float)pageSpUsedX                         , (float)pageSpUsedY);
            g2.drawString("x ad", (float)pageSpUsedX + (float)pageSpUsedWidth, (float)pageSpUsedY);
            g2.drawString("x bs", (float)pageSpUsedX                         , (float)pageSpUsedY + (float)pageSpUsedHeight);
            g2.drawString("x bd", (float)pageSpUsedX+ (float)pageSpUsedWidth , (float)pageSpUsedY + (float)pageSpUsedHeight);
                    return Printable.PAGE_EXISTS;
        }But the result is not what I expected to be....
    I am working at a program that have to print 'something' on paper's labels
    placed in a normal sheet format A4.
    and for this purpose it is very important to have the contrlo where the letters are wrote..
    I don't know what it is wrong and I need some help..
    thank you in advance..
    regards
    tomyMrsangelo

    hi Andre,
    thank you to answering me,
    I tried with your code but still I have not the control that I would have printing.
    Perhaps I misunderstand the role and the means of the parameters used for set the printable
    area.......
    For example.. when I set the margins in this way:
    MediaPrintableArea area = new MediaPrintableArea(10, 10, 170, 255, MediaPrintableArea.MM);
    I expect to have one area printable with the shape of a rectangle that, on a sheet of
    paper A4 format, begin in the corner up to left in the point (5, 10) and have a horizontal size
    of 180 millimeters and a vertical size of 265 millimeters.
    But this is not happen..., I measured the horizontal side in 150 millimeters (instead 170) and
    the vertical size in 248 millimeters (instead 255)....
    Measuring the coords of the corner on top to left, I got (5, 13) and not (10, 10).
    .....I tried with other values of parameters and never I got the exact values that I expected to have.
    Having to print labels glued on a paper sheet - A4 format,
    *I need to be sure that when the statement
    g2.drawString("x", 0, 0);
    is executed
    The character x is wrote, on the paper, at the point 10, 10. *
    Perhaps
    g2.drawString("+", 0, 0);
    is not the right operation to get this target..... ????
    Regards
    tonyMrsangelo

  • How can I print with a wider left margin in Preview? (OSX 10.5)

    How can I print with a wider left margin in Preview? (OSX 10.5)
    To punch Binder Holes.
    Should be easy ... Make a Custom page with a wider left margin ... easy to set up, but it does not actually work for any printer I am connected to.
    Info so far:
    Found an older post from 2002 ... "Make a custom page"
    Mac Help has a limited, simple, incomplete answer: "Make a custom page"
    Tried three printers. One Postscript Level 3 One Level 2 and one non postscript
    Switching between page types in the drop down shows a change in the print preview, and the floating information shows the correct page size and larger left margin... but the "Custom Page Size" does not show a larger left margin, in the preview, no mater how it is set.
    There also appear to be a relation ship between the radio Buttons for scale and the margin settings.
    Test prints have simply cut off the left side of the document, and scaled the document from the right side in and the top down.
    Printing a PDF from Preview
    MacBook Pro
    OSX 10.5.6
    Thanks
    Peter

    Thanks ... tried the Paper Handling, but no lock.
    Based on the fact that any scaling, "moves" the image down and to the left on the paper ...
    Th only "work around" solution is to ...
    Rotate the PDF page 180, then scale slightly (90% or so ...)
    This pushes the upside down page, down and to the left.
    While this is the opposite of what is desired, the print is then correct when
    it is punched and placed into a three ring binder.
    Assumption is the application that creates the documnt, needs to have the paper margins set. The reality is, an application like Preview, that does not "create anything", needs to handle existing documents PDF, JPEG and print to Custom Page configurations.
    ie: In Preview, Custom Page does not work correctly,
    Thanks allfor the comments and help ...

  • How to set and save Custom Print Settings in Aperture?

    How to set and save Custom Print Settings in Aperture
    Hi,
    I am printing 12x18" images on 13x19" sheets. I find it difficult to enter the 13x19" dimensions because each value jumps to another random value when I move to enter the second dimension. For instance 13 jumps to, say, 8.5 as I type 19 into the second box. Same with the sheet dimensions.
    Also, when I finally get it all correctly, the margins don't set themselves automatically - which I would I expect.
    Then, even though I save the setting by clicking Save Setting at the gear below, next time I turn Aperture on, it's all gone.
    Any ideas? Thanks.
    Raphael

    For me, it is working with these settings, Raphael.
    Does your image have a 12x18" aspect ratio? You may want to crop it to the desired aspect ratio before printing.
    I can only test with Aperture 3.6 on Yosemite 10.1.

  • How to set page margins in Numbers 3

    I just migrated from MS Excel after decades of use. I can't find out how to set page margins using the new Numbers 3 version. I believe I've exhausted all reference materials and the most relevant was an method in Numbers 8 & 9... both of which have a different top menu selection.  The answer is probably right in front of me and simple as it sometimes happens when learning new software...

    Hi caforestfire,
    There is no direct equivalent to page margins in Numbers 3.0. It's more oriented toward sharing on the web and on iPad screens than toward traditional printing.
    However, there are ways to achieve the effect of margins.  The idea is to first position your content (tables, charts, etc) on the canvas of a sheet, using rulers and guides if you want (you can drag the rulers onto the canvas to help in placement):
    Then you File>Print and in Print Preview fiddle with the slider until you get the white space you want around your content:
    Then click Print.
    For many purposes it works quite well. It's just a different approach from what we're used to in Excel, and the old Numbers 2.3.
    SG

  • Set MARGIN  of Printer with REPORT6

    I have some reports and to print some of them, the margin of prinetr must set to .5 and user must set it before any print. how can i set it in report builder with code or is there any way to solve this problem.
    and users dont do this.

    Hi,
    On Windows the printer margin is controlled by the printer driver. This is called the printer or hardware margin. To this, you add the margin defined inside the report definition. The sum total is the margin that you will see on the report's printed output. For example, if the default printer margin is 2 cm, and you have defined 3 cm inside the report defintion, you should see a total 5 cm margin on the printed output. This should be consistent across prints. So you can reduce / increase the report definition margin, to get the exact output that you want in the printed output.
    However, if you find that even by making the report definition margin zero you cannot get the margin that you want, then you can upgrade to version 6i patchset 15. From this patch onwards, the printer default margin is ignored, and only the report definition margin is counted.
    Also, you can find useful notes if you serach for "margin" on Metalink.
    Navneet.

  • How to change margin value in mode booklet printing Adobe Reader X ?

    How to change margin value in mode booklet printing Adobe Reader X ?

    Is this a form you created in Acrobat or is it a form that you're using with Reader? If the latter, there's nothing you can do if the field has been set up to format the field with a £ for the currency symbol.

  • How to set printer options when direct printing from Linux AS Sevr.?

    We have a problem like this: Our app server is a 10g R2. We want to DIRECTLY print reports to a HP LaserJet 1320 PCL 6 which is attached to a Windows print server.
    We can print the reports from the Oracle Forms (we use reports builder to create a PDF in a directory and then using HOST command we print it).
    The command we use is lp -d LaserJet sicl_rcpdebtnt_5.pdfProblem is the printout comes with the top 10% of the page not printed. i.e. the printing starts from about 10% of the PDF. The header and top information is not printed.
    We tried the scaling option: lp -o scaling=75 -d LaserJet sicl_rcpdebtnt_5.pdfBut that also has no effect.
    What can we do to print the entire PDF in ONE page. When we open the PDF in Windows and prints it we have to say Fit to printer margins for the printer's page scaling property.
    How to set this in command line Linux???

    Since you are not printing directly from Reports (destype=printer) this is not really a Reports issue I guess. Maybe you should ask this in a Linux forum.
    However:
    we have to say Fit to printer margins looks to me that there is a mismatch between your Report design and paper format. Check page size and margins in Reports Builder.

  • Being new to working with Mac, I was wondering if anyone can tell me how to set my Mac Book Pro wirelessly to the Canon Pixma Pro9000 Mark ll? My husband had gotten this printer and the sales person said that it can be set up wirelessly to my Mac Book Pro

    Being new to working with a Mac, I was wondering if anyone can tell me step, by step on how to set up my Mac Book Pro(Mid 2012) wirelessly to a Canon Pixma Pro9000 Mark ll that my husband had gotten me? Sales person told him that it's compatiable to my Mac Book Pro, Mtn Lion, but I do not see it and I don't see how to do it wirelessly. Any help would be appreciated. Thanks ;o)

    Hello:
    There is nothing wrong with asking questions.  There  are no dumb questions....answers, yes, but not questions. 
    If you set up your wi-fi router to establish a network, then both your printer and MacBook Pro will connect wirelessly.  *** I do not know what kind of router you possess, I don't want to suggest things that might not be relevant.
    Barry
    P.S. No need to apologize!  Most of the people here (none of us are Apple employees) enjoy trying to help others. 

  • How to set print option for a Billing document using T-code VF02

    Hi All,
    Please suggest me the way to set print option for a Billing document for T-code VF02 and please let me know how to get print preview for any particular Billing document?
    regards
    Anand.

    Enter the billing documents detail
    Goto Goto> Header>Output.
    Check the status for your output type in this screen.
    If it is green then come back to the VF03 screen.Enter the billing document number.
    Click on Billing document-->Issue output to.
    Press (CtrlShiftF1) or click on the icon beside "Print options".
    Here you can see the print preview.
    If the status is red then click on the processing log.Here you will get the error messages.
    If the status is in yellow colour,then click on the "Further Data" button
    Set "Dispatch time" as "4 Send immediately (when saving the application)"
    Before the print preview option you should make sure you have added correct output type to the relevant billing document. To do that, go to transaction VF02.
    Enter the billing document no
    Go to Menu option -> Go to -> Header -> Output
    In that screen you have to add relevant output type. (Standard output type is RD00)
    Add that & press enter key
    Highlight that line & press "Further Data" button
    Set "Dispatch time" as "4 Send immediately (when saving the application)"
    Press "Back" Button
    again select that line & go to "Communication method" button
    Set "Logical destination" as LOCAL"
    Don't mark "Print immediately" & "Release after output" ticks. If you mark them, sa soon as you save the billing document, you'll get a print out.
    Press "Back" Button
    Save
    Now form the initial "Change Billing Document" screen, Go to Menu option; Billing Document -> Issue Output to
    You can see that output type line appear.
    select that line & press "Print Preview" button or (CTRLSHIFTF1)
    You can see the print preview.
    Alternatively you can use VF31 to print multiple print outs at same time.
    If you want to get PDF outputs of billing documents, go to your printer settings in the your computer from Control Panel.
    Set PDF Writer as "Default Printer" (Right click & select "Set as Default Printer")
    Then normal way, print the billing from SAP.
    It'll automatically send to your PDF writer. You can save it to the path you want,

  • How to set up Canon printer via Netgear print server ps121 on new macbook

    I have bought a new Macbook (OS10.4.8). The Apple store gives a good deal if you buy a Canon ip4300 with it but I am having problems figuring out how to set up the printer to work thru my Netgear print server on my Netgear network. Can anybody advise:
    1. I know my print server is on port 192.168.1.5, but what kind of settings do I use, IPP or LPT or something else?
    2. Why can I not find the driver for the ip4300, even though I have used the CD that came with the printer and run the install program and the printer DOES work when I plug it directly into the USB port. Why does the Macbook come with drivers already installed for only a few ancient BJ Canons and why won't it show me where the driver for the ip4300 is since it is obviously already on the machine?
    I know Netgear treats its customers with contempt (Linksys even worse). But I would expect a little more simplicity from Canon and Apple. I know I am an orangutan but it still seems incredibly difficult, as if they have hidden the printer driver on the computer and as if Apple does not want you to install networked printers. Please don't tell me to RTFM, I have read the Canon manual, it tells you how to network with Windows, does not even mention Mac. Any advice appreciated.
    Macbook   Mac OS X (10.4.8)   Netgear PS121, Netgear WGT624v3 router, Canon ip4300 printer

    Hi zoevancouver,
    If you are not able to set up your Canon MP460 printer, take a look at the article below.  There is a link to the Canon website and compatible printers.  Since this particular model is not on the list, you may need to contact Canon for additional support.
    OS X: Printer and scanner software available for download - Apple Support
    https://support.apple.com/en-us/HT201465
    Regards,
    - Judy

  • HT1277 how to set up my email to print automatically

    I have an online menu where my clients can order online and I only have 45min for delivery. I need my incoming email orders to print automatically on my kitchen printer. How can I set up the rule in my email to do that?
    Thanks,
    AE

    Hi and Welcome to the Forums!
    To use the proprietary RIM Push email capability, you must have an adequate data plan from your carrier. The carriers host BIS for their BB users. Typically, BIS is not available via generic data plans. Many carriers call what is necessary The Blackberry Data Plan. Whatever they call it, it is the carrier who delivers BIS to their BB users -- contact them for assistance. Once you have a BIS-capable data plan on your BB (at whatever fees your carrier will charge, btw), you will then have Personal Email added to the email setup wizard.
    http://www.blackberryfaq.com/index.php/What_do_I_need_a_Data_Plan_for%3F
    Good luck!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

Maybe you are looking for

  • Wait for event step without callback

    Hi All, In 4.6C I have the following problem: We have a workflow that has a fork with 2 branches, with 1 necessary for continuing the fork. One of the branches has a dynamic parallel processing step on a multiline container element, where each parall

  • IPhoto an error after installing Mountain Lion

    Having installed Mountain Lion it now says that there was an error installing iphotos and i can not access my photos at all. How do i find my photographs?

  • Next & Prev buttons in Navigation pane appear in skin but not in HTML

    I have customized the standard template and its components in flash according to my requirement and created a skin. When the skin is generated all the images/buttons gets displayed perfectly but on generation with FlashHelp the Next, Prev and Sync bu

  • Assigning Employee to Sold-to Parties

    Hi Experts, I have created authorizations for Accounts, with this an employee can see, only those sold-to parties which he is responsbile for. Now the huge task is assigning employees to the sold-to party, becuase there are around 300 employees each

  • Top worst query on table

    Hi all, i am trying to use V$sqlarea,V$sql but i am not able to find out Top 10 worst query on particular table. Which view shuld i use? Please guide Oracle 10g RAC on IBM AIX Thanks & regards, Neerav