How to set Jspx page width and hight programatically ?

Hi All ;
i need to browse a jspx page has Different width & hight sizes ;
Please Can SomeOne tell me ow to set Jspx page width and hight programatically ?
Regards;

In that case you need to use JavaScript.
Resizing the browser window in JavaScript is done by using window.resizeTo(400, 400);
I
Thanassis

Similar Messages

  • How to set a minimum width and height for a stage or scene?

    Hello,
    Does anyone how to set a minimum width and height for a stage or scene?
    I tried listening for width/height property value changes and then adjust the width/height if necessary, but that causes unpleasant flickering of the window.
    In JavaFX 2.1 beta SDK for Mac OS, the Stage class has setMinWidth() and setMinHeight() functions which work very well.
    I'm wondering what's the equivalent way to do that when using the FX SDK for Windows.
    Any help is appreciated!
    Thanks.

    I was wondering how to enforce a minimum stage size with JavaFX 2.0.3.The same flickering way you are currently doing it. See: http://javafx-jira.kenai.com/browse/RT-15200 "Need a way to set the minimum size of a window"

  • 2 Question How to set the page size and  full screen

    I am looking to find out how to set the page to be 1024 by
    768 static and also how to force a browser window to go to full
    screen. Thanks

    Hi Ludek,
    i could solve the issue by using the follwing code.
    report = new ReportDocument();
    PageMargins customPageMargin = report.PrintOptions.PageMargins;
    report.PrintOptions.PaperOrientation = PaperOrientation.Portrait;
    report.PrintOptions.PaperSize = PaperSize.Paper10x14;
    customPageMargin.rightMargin = 1;
    customPageMargin.topMargin = 0;
    customPageMargin.bottomMargin = 0;
    report.PrintOptions.ApplyPageMargins(customPageMargin);
    Thanks for you help.
    Regards,
    smitha.

  • How to set the page size and the margins programatically

    Hello,
      I am working with crystal report XI Release2 and asp.net.
    One of my report is having 4 graphs in a single report.In order to display all the graphs in one page i have set  the paper size as A3.(Via Crysta report ->File->Page set up)
    But the page size A3 is not provided by all printers.So problem comes when the application is diployed on a machine which does not support A3 Printer.All the graphs will not be shown on a single page.
    Also Each and Every time ,when the application is diployed on a machine,user has to open the crystal report and adjust the page size accordingly to get all the reports on a single page.
    This is a kind of usability issue also.
    Is it possible to set the page size and the margins programatically say for eg 11 X 17.so that with out doing anything all the 4 graphs will get displayed on a single page ?
    Please let me know if you require more information regarding this issue.
    Thanks in advance.
    smitha.

    Hi Ludek,
    i could solve the issue by using the follwing code.
    report = new ReportDocument();
    PageMargins customPageMargin = report.PrintOptions.PageMargins;
    report.PrintOptions.PaperOrientation = PaperOrientation.Portrait;
    report.PrintOptions.PaperSize = PaperSize.Paper10x14;
    customPageMargin.rightMargin = 1;
    customPageMargin.topMargin = 0;
    customPageMargin.bottomMargin = 0;
    report.PrintOptions.ApplyPageMargins(customPageMargin);
    Thanks for you help.
    Regards,
    smitha.

  • Help on how to Set a page length and width.

    Hi guys I'm kind a new to java JDBC and Jasper.
    I'm currently creating my senior project, developing a POS system using Java JDBC, MySql and JasperReport.
    I'm now on the finally stage of my project polishing stage.
    Now here is my problem.
    My adviser wanted my to print sale Invoice using and ordinary Printer let say Espon LX 300 which is available on our Cmpter Lab. He want me to print Sale Invoice using continues paper and try to simulate an actual thing. But I don't know on how to set up a custom paper size in Java or trying to select printer from your system or in your network.
    here is the sample of the code:
    void PrintInvoice(String databaseName,String userName,String password,String reportFile,String Invoice_Reprint)
            HashMap hm = new HashMap();
            hm.put("REPORT_DATE", saledate_tbox.getText());      
            hm.put("REPORT_VAT", vat_tbox.getText());
            hm.put("REPORT_SUBTOTAL", subtotal_tbox.getText());
            hm.put("REPORT_TOTALPAYMENT", total_tbox.getText());
            hm.put("REPORT_CASH", cash_tbox.getText());
            hm.put("REPORT_CHANGE", change_tbox.getText());
            hm.put("REPORT_POS",POS);       
            hm.put("REPRINT", "REPRINT");
            Connection connection = null;
            ResultSet resultSet = null;
            Statement statement = null;
            try{
            Class.forName(JDBC_DRIVER);     
            String query1 = "select invoice.idinvoice as 'Invoice No'" +
                    ",CONCAT(customer.firstname,' ',customer.lastname) as 'Customer'" +
                    ",invoice.date as 'Date-Time'" +
                    ",item.description as 'Description'" +
                    ",sum(invoice_items.quantity) as 'Quantity'" +
                    ",Format(item.regular_price,2) as 'Unit Price'" +
                    ",Concat((invoice_items.discount*100),'%') as 'Whl Disc'" +
                    ",Format(invoice_items.price,2) as 'Price'" +
                    ",employee.username as 'Employee'" +
                    ",Format(invoice.totaltax,2) as 'Vat'" +
                    ",Format(invoice.total,2) as 'Total'" +             
                    ",Format(invoice.cash,2) as 'Cash'" +
                    ",Format((invoice.total-invoice.totaltax),2) as 'Subtotal'" +               
                    ",Format((invoice.cash-invoice.total),2) as 'Change'" +
                    " from invoice,item, invoice_items,customer,employee " +
                    "where invoice.IDINVOICE = invoice_items.IDINVOICE " +
                    "AND invoice_items.UPC_CODE = item.UPC_CODE " +
                    "and invoice.idcustomer = customer.customerid " +
                    "and invoice.idemployee = employee.idemployee " +
                    "AND invoice.idinvoice = (select idinvoice from invoice " +
                    "where idemployee = (select idemployee from employee where username = '"+soldby_tbox.getText()+"') " +
                    "AND idinvoice = '"+Invoice_Reprint+"' ) GROUP BY item.DESCRIPTION";
            connection = (Connection) DriverManager.getConnection(databaseName,userName,password);
            statement = (Statement) connection.createStatement();
            resultSet = statement.executeQuery(query1);
            JasperDesign jasperDesign = JRXmlLoader.load(reportFile);
            JasperReport jasperReport = JasperCompileManager.compileReport(jasperDesign);        
            JasperPrint jasperPrint = JasperFillManager.fillReport(jasperReport, hm, new   JRResultSetDataSource(resultSet));        
            JasperExportManager.exportReportToPdfFile(jasperPrint, PDFEXPORT);        
            JasperViewer.viewReport(jasperPrint);
            JasperPrintManager.printReport(jasperPrint, false);       
          }catch(Exception ex) {
             String connectMsg = "Could not create the report " + ex.getMessage() + " " + ex.getLocalizedMessage();
             System.out.println(connectMsg);
          finally{
            try                                                       
                  statement.close();                                     
                  connection.close();                                    
               } // end try                                              
               catch ( Exception exception )                             
                  exception.printStackTrace();                           
               } // end catch    
        }My code print the report on the default printer and default printer setting.
    I hope someone out there can help me thx alot. by the way I uses Ubuntu as my OS.
    The theme of my Senior Project: POS System Using Open Source.
    Hey can someone suggest a project tag line or a better theme cause I believe in the ideals of Open Source,
    Thx

    Try to define ENTER this way & try
    class cl_abap_char_utilities definition load.
    DATA : BEGIN OF enter,
    x type c value cl_abap_char_utilities=>cr_lf,
    END OF enter.
    PS : I am not 100% sure about this.

  • How to set the BARCODE width and length for label printing..

    Hi All,
    How to set the Code 39 barcode label format in the sizxe of 0.20" * 1.4". By default while printing barcode size exceeds my current requirement. Please let me know to customize the size of barcode labels.
    Thanks.

    I don't know what you mean by "Code 39" because my Output Designer software doesn't offer that barcode (or do you mean "code 3 of 9?). In any case, are you trying to control the size of the text (which is what I think of when you refer to "label")? If you are, then just change the font & size. If you are wanting to modify the physical characteristics of the barcode itself (height & length for a certain number of characters) then you are probably out of luck. Or at least in for some trial & error.
    There are a series of "barcode.xxx" files in the 'config' folder where Output Designer was installed to. These are text files that contain the physical characteristics of the various barcodes for various printers. The parameters that you would be interested in is the height and width of the bars (black & white). For example, a barcode might be defined as .400 high with narrow bars 3 "dots" wide, wide bars 9 "dots" wide and white space the same or different. Presumably changing these values would affect the generated barcode. For example, in this example the wide bars are 3 times the width of the narrow bars so I would assume that relationship would have to remain. To make the resulting barcode shorter you would then use 2 for the narrow and 6 for the wide.
    You would have to make the change in the file(s) that would be used for your printer(s).
    There are four width values for each of the parameters. Most of the barcodes only use 2 but some have 4. I'm assuming that when there are 4, like in "4 8 12 16", that the barcode definition has 4 different widths of bars and/or spaces.
    There is no guarantee that the scanning hardware & software will "see" and interpret the resulting barcode correctly.

  • How to set a page header and footer of an excel file i'm creating

    Hello !
    SORRY MY ENGLISH is very BAD.
    I tried to set page header and footer in Excel sheet with ABAP  ole
    DATA : BEGIN OF enter,
    x(1) TYPE x VALUE '0D',
    END OF enter.
    DATA : format(255) TYPE c.
    FORM set_page_sheet.
    CALL METHOD OF excel 'ActiveSheet' = sheet.
    CALL METHOD OF sheet 'PageSetup' = pagesetup.
    SET PROPERTY OF pagesetup 'Orientation' = xllandscape.
    SET PROPERTY OF pagesetup 'PrintTitleRows' = '$9:$12'.
    CLEAR format.
    ERROR
    CONCATENATE 'PAGESHEET' enter-x 'PAGE &P/&N' INTO format.
    ERROR
    SET PROPERTY OF pagesetup 'RightHeader' = format.
    CLEAR format.
    CONCATENATE ' Text 1 ' enter-x 'Text 2'
    enter-x 'Text 3 ' INTO format.
    SET PROPERTY OF pagesetup 'RightFooter' = format.
    FREE OBJECT pagesetup.
    ENDFORM. " set_page_sheet
    Activate report -
    ERROR - The enter-x must by data type c or another then data type x
    Thanks for answer.

    Try to define ENTER this way & try
    class cl_abap_char_utilities definition load.
    DATA : BEGIN OF enter,
    x type c value cl_abap_char_utilities=>cr_lf,
    END OF enter.
    PS : I am not 100% sure about this.

  • How to set mutable cell width and height in a jlist?

    Hello,
    i wrote a jlist cell renderer object to able to render a jlabel for the unselected items and a wide and high jpanel with images when an item is selected.
    The jlist render all items at the same dimension.
    How can i change this built-in behavior?
    i printed the items preferedsize:
    java.awt.Dimension[width=340,height=140]
    java.awt.Dimension[width=275,height=75]
    java.awt.Dimension[width=275,height=75]
    java.awt.Dimension[width=275,height=75]
    java.awt.Dimension[width=275,height=75]
    java.awt.Dimension[width=275,height=75]
    java.awt.Dimension[width=275,height=75]
    Message was edited by:
    fazekaim
    ok, i give for every index pos a fix jpanel object, and it is working.
    What i would like is a mouse selection and the selected item/cell should be rendered by a component with different dimension (containing more information). but this doesn't work.
    Is it possible, that the JList cashes the cells dimensions???
    Message was edited by:
    fazekaim
    Message was edited by:
    fazekaim

    i just want to change a cell for another when i click on it.
    there are names in the jlist. after having click on one of them, a description panel could be appears in the list instead of the short name. it' a simple ui effect, i think.
    is there any other way than write a custom jlist implementation?

  • Setting different pages widths in different sections - Pages 5.2

    In Pages 5.2, how does one set different page widths (margins) in different sections?

    You can't. Margins apply to the entire document.
    What you can do is set the margins to their max width and then use left and right indents for the sections you want narrower.
    Peter

  • Hi, I am using Indesign CS6, How to set the page size in Inches.

    Hi, I am using Indesign CS6, How to set the page size in Inches.

    All fields in InDesign can be entered in any measurement system. So, if you want to make an 8"x10" document and go to File>New Document and the window looks like this:
    …you can type either 8 in or 8" into the Width field like this:
    …and when you move to the next field, it will convert the eight inches into the equivalent number in the unit of measure that it is using at the moment, like this:
    … (203.2 milimeters is the same as 8 inches). You can also enter a different measurement unit into other fields once the file is created, such as the width or height of a frame, or the position of an object in the X and Y coordinates.
    If you would rather just work in inches instead of having to type the inches mark or abbreviation, go to InDesign>Preferences>General and select the Units & Increments tab. There you will see Ruler Units for Horizontal and Vertical at the top of the window. Set them to Inches and all of the fields will display in inches. If you do that to an open document, you will change the unit of measure for that document. If you do it while no documents are open, it will change the unit of measure for any new documents you create. To change the unit of measure for existing documents, you will have to open each and make the change.

  • How to set a fixed width for a box

    Hi there,
    Struggling here.... must admit. 
    I need a solution whereby I can set a fixed width for a box that is grouping two buttons.  I suppose generally, I want to know how to set a fixed width for anything element.
    See the picture below.  I want the two buttons to stay the same distance apart, and I want the grouped buttons to stay the same distance from the right edge of the window, even as a user resizes the window.
    This is what happens when you reduce the size of the window .....
    I would like to stop this from happening.
    I can't figure out how accomplish keeping the parent div a fixed width, and a fixed position from the right side of the window, so the buttons won't overlap.
    Perhaps I'm doing the whole thing wrong. 
    I mean, is there a way to accomplish this without grouping the buttons?  That is, make the buttons fixed width, fixed distance apart from each other, and fixed distance from the right side of the window, even as the user resizes the page?
    I am trying to accomplish this using the Min/Max width settings, but given that there are so many different units to choose from, and the fact that when I place a button or box on the screen, it seems to be creating that button or box with a percentage-based width, I don't know how many pixels to set it to.... sigh....
    Many thanks in advance for your help.
    Sam

    Okay after much futzing I figured out at least part of the solution I need, but if someone knows of a more efficent way to do this please let me know. 
    I set a fixed minimum width in pixels for both of the buttons at 156px.
    I then made the left button float left and the right button float right.
    I then made the parent div for the buttons float right.
    That made the buttons stay the same size.
    The only thing I need to figure out how to do now is make the parent div stay a consistent distance in pixels from the right.  I tried setting a right margin but that didn't work.  As you size the window down, the div gets closer to the edge, until it passes it.  

  • Control width and hight ??

    Can someone plz tell me how I can control width and hight of my printing?? My code:
            public int print(Graphics g, PageFormat pf, int pi) throws
            PrinterException
                if (pi >= 1)
                   return Printable.NO_SUCH_PAGE;
                   Graphics2D g2 = (Graphics2D) g;
                   double height=pf.getImageableHeight();
                   double width=pf.getImageableWidth();
                   g2.translate(pf.getImageableX(), pf.getImageableY());
                   g2.drawString("side :"+(pi+1), (int)width/2,
                   (int)height-g2.getFontMetrics().getHeight());
                   g2.translate(0f,0f);
                   g2.setClip(0,0,(int)width,
                   (int)(height-g2.getFontMetrics().getHeight()*2));
                   g2.setColor(Color.black);
                   paint(g2);
                   return Printable.PAGE_EXISTS;
             public void PrintPage()
                  PrinterJob printJob = PrinterJob.getPrinterJob();
                  printJob.setPrintable(this);
                  if (printJob.printDialog())
                     try { printJob.print(); }
                     catch (Exception PrintException) { }

    ...with PrintJob ...e.g
            Toolkit tk = Toolkit.getDefaultToolkit();
            int [][] range = new int[][]
                new int[] { 1, 1 }
            PageAttributes.ColorType ct = PageAttributes.ColorType.MONOCHROME;
            PageAttributes.OrientationRequestedType ot = PageAttributes.OrientationRequestedType.LANDSCAPE;
            PageAttributes.OriginType ort = PageAttributes.OriginType.PRINTABLE;
            PageAttributes.PrintQualityType pqt = PageAttributes.PrintQualityType.HIGH;
            PageAttributes.MediaType mt = PageAttributes.MediaType.A5;
            int [] printRes = new int[]{1,1,3};
            PageAttributes pa = new PageAttributes(ct, mt, ot, ort, pqt, printRes);
            pa.setPrinterResolutionToDefault();
            JobAttributes jobAttributes = new JobAttributes(1, JobAttributes.DefaultSelectionType.ALL,
              JobAttributes.DestinationType.PRINTER, JobAttributes.DialogType.NATIVE, "file", 1, 1,
              JobAttributes.MultipleDocumentHandlingType.SEPARATE_DOCUMENTS_COLLATED_COPIES, range,
              "\\\\110APPS\\HP5FrontOffice", JobAttributes.SidesType.ONE_SIDED);
            PrintJob job = tk.getPrintJob(dummy, "Print", jobAttributes, pa);
            if (job != null)
                Graphics pg = job.getGraphics();
                System.out.println("Page Dimension : " + job.getPageDimension());
                pg.drawRect(20,20, 240, 120);
                pg.drawString("Hello World", 50, 50);
                pg.dispose();
                job.end();
            }

  • How to set displayed column width for a search help

    I have created an elementary search help for a custom field with a value table behind it.
    The search help functions correctly, but when displayed the column widths are all 10 characters. The user has to adjust the column to view the descriptive text.
    Can anyone tell me how to set default column widths for the help?

    Please  open you Elementary search  help  and see the Column  width   behind the Fields of your ...there  increase the width of the fields
    "Activate it  and refresh
    reward  points if it is usefull .....
    Girish

  • How to set the page size

    Hi,
    How to set the page size of a B tree node in berkeley db java edition?
    thanks.

    The two systems have different performance characteristics. If you are concerned with the performance characteristics, then the best way to tell is to benchmark them.
    By the way, both BDB and BDB JE are B-trees.

  • How to set a specific width to all the TextInputs used in a mxml file on its creation complete?

    How to set a specific width to all the TextInputs used in a mxml file on its creation complete?

    Hi subhajit nag,
    I think the best approach would what I say is if you can make use of a Global variable or using a Singleton class having a variable which can be accessed globally through out the application.
    Below is the sample what I am talking to:
    So in below example you can access the variables textInputWidth and textInputHeight globally throghout the application since you have decalred them in main mxml file.
    You can access these variabled in another mxml file as Application.application.textInputWidth and Application.application.textInputHeight. So if at all you are required to modify these values you are only required to modify at a single place in main mxml file..thats it.
    If you are use any Singleton classes like ModelLocator you can place these variables in this class and refer from that class.
    Hope this resoved your problem..
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
    <mx:Script>
      <![CDATA[
       [Bindable]private var textInputWidth:int = 250;
       [Bindable]private var textInputHeight:int = 25;
      ]]>
    </mx:Script>
    <mx:Canvas id="canvas1">
      <mx:TextInput id="txt1" width="{textInputWidth}" height="{textInputHeight}"/> 
    </mx:Canvas>
    <mx:Canvas id="canvas2">
      <mx:TextInput id="txt2" width="{textInputWidth}" height="{textInputHeight}"/> 
    </mx:Canvas>
    <mx:Canvas id="canvas3">
      <mx:TextInput id="txt3" width="{textInputWidth}" height="{textInputHeight}"/> 
    </mx:Canvas>
    <mx:TextInput id="txt4" width="{textInputWidth}" height="{textInputHeight}"/>
    <mx:TextInput id="txt5" width="{textInputWidth}" height="{textInputHeight}"/>
    </mx:Application>
    If this post answers your question or helps, please kindly mark it as such.
    Thanks,
    Bhasker Chari 

Maybe you are looking for

  • Windows 7 - can't use ipod Touch

    I recently installed Widnows 7 on my Pc and have not been able to use my touch with it since. When I first plugged my ipod touch in it was recognized as a camera. I had this issue with Vista when I first bought my touch. The fix I used back then did

  • Deskjet 3050 All-In-One J610 only prints blank pages

    Hi, All of a sudden, my printer stopped printing. The ink levels in the cartridges look fine in the HP utlity, and I did the self-cleaning steps, but when I print something, only a blank page comes out. There is some ink around the edge of the paper,

  • Import an Address book FROM Access

    I have tried all the methods suggested, including making a text file with comma separated fields, and used the wizard to import it into Thunderbird, but it does not work.

  • Belle Software Upgrade wiped loads of my games!!

    Belle upgrade on my Nokia N8 has just removed loads of my game sinlcuding Angry Birds, Angry Birds Seasons and Angry Birds Rio....Aaarrrgghh...how do i get these back?

  • Convert vi 5.0 to 2013

    Hello I would like to convert this vi 5.0 for labview vi 2013 This vi is an example provided by NI, but I find this only in version 5.0 Thank you very much for your helphttp://forums.ni.com/t5/forums/postpage/board-id/VersionConversion/tab/rich Attac