How do I add a close command to multiscreen layouts?

I need to add a close command multiscreen HTML5 screen layouts that will work on multiple platforms and browsers. I have 3 screen layouts defined: Desktop, Tablet, Mobile. These are called by a responsive design web application and display based on the screen width of the platform calling the help. My problem is that there is a requirement to be able to close the help. To do this I have added the javascript code:
</a>
       <a href="javascript:window.close()" class="wPrintButton"><img
       src="Close.png" alt="" class="wPrintButton" border="0" />
in each of the layouts to allow the user to close the help browser tab/window.
My Desktop layout is based on the stock desktop. I added this command Topic.slp and SearchResults.slp d just to the right of the Print icon.
My Mobile lay out is based on the stock iPhone. I added this as an additional row in the homepage links to the Home.slp.
My Tablet layout is based on the stock iPad. Again I added this as an additional item to the homepage links to the Home.slp.
My problem is - it appears that the window.close() javascript will not work with iOS. Has anyone incountered a similar problem and how did you deal with it?

I had another idea that I am pursuing. I am looking into extending the current renderer CommandNavigationRenderer and will render another goLink just after the current goLink that will execute a close action. I was able to re-direct the rendering by added an override render-kit block in my current faces-config.xml file.
<render-kit>
<renderer>
<component-family>org.apache.myfaces.trinidad.Command</component-family>
<renderer-type>oracle.adf.rich.NavigationItem</renderer-type>
<renderer-class>com.riscs.ui.backing.jsp.components.ClosableCommandNavigationItemRenderer</renderer-class>
</renderer>
</render-kit>
If this works I am planning on extending the commandNavigationItem by creating a ClosableCommandNavigation tag and add a "closeAction" tag that will determine if a close item should render.
Preliminary work looks promising. I will update if I make progress...please let me know if I am crazy.
Thanks.

Similar Messages

  • How do I add a close window button/image

    All I want to do: Add a close window button (round/square with an "x" through it) to either one or many html files. I don't see how to do this.
    Using RoboHelp 8 HTML and WinXP. Thanks.

    Ahh I see now. You are asking where to obtain such an image!
    The RoboHelp Gallery doesn't contain one. Sorry. You will need to obtain one from any number of other locations.
    You might look at the following link for one possibility.
    Icon Archive
    Here are a couple from my own colloection. You might right-click and save as.
    There are also a number of packages you may purchase or find. Perhaps the following link will help.
    Click here to search Google
    I cannot advise on the legal implications of using said images.
    Cheers... Rick
    Helpful and Handy Links
    RoboHelp Wish Form/Bug Reporting Form
    Begin learning RoboHelp HTML 7 or 8 moments from now - $24.95!
    Adobe Certified RoboHelp HTML Training
    SorcererStone Blog
    RoboHelp eBooks

  • How do I add a user command to a Adobe Form Button?

    Hi,
    I want to add a user command to a Adobe Form button, but have no idea how to do it? (Since the material I have only mentioned how to do it by using JSP pages). This is a question comes from PCR. Thanks.

    Formscentral does not support forms with digital signature workflows. I suggest you see if our Echosign product meets your needs.

  • How do i add an image in my Grid Layout

    I want to add an image form my directory on to a grid. I do not want to add a button, because that is all i seem to be seeing online. I just simply want to add a image from my directory into my grid.
    setLayout(new GridLayout(3,2));
    .......How do i add my image.
    image is called picture.jpg
    Thankyou
    Hemant

    Take a look to this code :
    You can make a pane component in which an image is displayed
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.border.Border;
    * Pane which displays an image.
    * @author     Antoine Lemoine
    * @version     1.0 (Released November 26, 2005)
    public class ImagePane extends JPanel
                   Constructors
         public ImagePane(ImageIcon imageIcon)
              setOpaque(false);
              setImage(imageIcon);
              this.autoSize = false;
              this.conserveProportions = false;
              this.minimizeOnly = false;
         public ImagePane(String imageFile)
              this(new ImageIcon(ClassLoader.getSystemResource(imageFile)));
         public ImagePane(String imageFile, Color background, Dimension dimension)
              this(imageFile);
              setBackground(background);
              setPreferredSize(dimension);
                   Protected redefined methods
         protected void paintComponent(Graphics g)
              super.paintComponent(g);
              int w = imageIcon.getIconWidth();
              int h = imageIcon.getIconHeight();
              Insets margin = getInsets();
              if (autoSize)
                   ((Graphics2D)g).setRenderingHint(
                        RenderingHints.KEY_ANTIALIASING,
                        RenderingHints.VALUE_ANTIALIAS_ON);
                   int w2 = getWidth();
                   int h2 = getHeight();
                   if (conserveProportions)
                        if (w2/w>h2/h) { w2 = h2*w/h; }
                        else { h2 = w2*h/w; }
                   if (!minimizeOnly || w2<w)
                        w = w2;
                        h = h2;
              g.drawImage(imageIcon.getImage(),margin.left,margin.top,w,h,this);
                   Public methods
         public void setImage(ImageIcon imageIcon)
              Insets margin = getInsets();
              if (imageIcon!=null);
                   this.imageIcon = imageIcon;
                   setPreferredSize(
                        new Dimension(
                             imageIcon.getIconWidth()+margin.left+margin.right,
                             imageIcon.getIconHeight()+margin.top+margin.bottom));
         public void setBorder(Border border)
              super.setBorder(border);
              Insets margin = getInsets();
              int w = (imageIcon!=null ? imageIcon.getIconWidth() : 0);
              int h = (imageIcon!=null ? imageIcon.getIconHeight() : 0);
              setPreferredSize(
                   new Dimension(w+margin.left+margin.right,h+margin.top+margin.bottom));
         public void setMinimizeOnly(boolean minimizeOnly)
              this.minimizeOnly = minimizeOnly;
         public void setAutoSize(boolean autoSize)
              this.autoSize = autoSize;
         public void setConserveProportions(boolean conserveProportions)
              this.conserveProportions = conserveProportions;
                   Private attributes
         private ImageIcon imageIcon;
         private boolean autoSize;
         private boolean minimizeOnly;
         private boolean conserveProportions;
    }

  • How do I add a close button to an item in a NavigationPane

    We are creating tabs (commandNavigationLink) dynamically for a NavigationPane that are driving data in a set of iframes. We are using the tabs to show and hide the iframes which really works well.
    My issue is that I cannot figure out how to put a close buton on a commandNavigationLink. As this is the only component allowed in a NavigationPane I am at a standstill.
    I am starting to look at extended the ADF components to add this capability, however this does not seem trivial at this point.
    Any thoughts???

    I had another idea that I am pursuing. I am looking into extending the current renderer CommandNavigationRenderer and will render another goLink just after the current goLink that will execute a close action. I was able to re-direct the rendering by added an override render-kit block in my current faces-config.xml file.
    <render-kit>
    <renderer>
    <component-family>org.apache.myfaces.trinidad.Command</component-family>
    <renderer-type>oracle.adf.rich.NavigationItem</renderer-type>
    <renderer-class>com.riscs.ui.backing.jsp.components.ClosableCommandNavigationItemRenderer</renderer-class>
    </renderer>
    </render-kit>
    If this works I am planning on extending the commandNavigationItem by creating a ClosableCommandNavigation tag and add a "closeAction" tag that will determine if a close item should render.
    Preliminary work looks promising. I will update if I make progress...please let me know if I am crazy.
    Thanks.

  • How do I add a 'close this window' button to a page please?

    I have tried using the only snippet I can find and it looks good but just does not work. Any ideas would be greatly appreciated. Thanks
    Jim

    A Google search for javascript close window go this response: http://www.google.com/search?client=safari&rls=en-us&q=closewindowjavascript&ie=UTF-8&oe=UTF-8.
    An easy one that I found was:
    <xmp>
    <A href="javascript: self.close ()">Close this Window</A>
    </xmp> *(Ignore the <xmp></xmp> tags when copying)*
    And works fine. When you add the snippet enlarge the results box as it tended to cut off some of the text when published.

  • How do you add read aloud to a fixed layout book?

    I have seen some ibooks (childrens books) with read aloud abilities. I know you have to do some programming but what program do you use to edit the code, can you preview it in ibooks (on ipad) if you modify the code, and is there a non-programming way to add audio/speech to your ibooks through ibooks author? Does anyone know the process or what steps and programs needed to add the read aloud feature to an ibook? (I know there are many others out their who would like to know the answers to these questions). Thanks.
    Also, I have HD images (2000x1462) for my ibook in ibooks author and when I preview it on an ipad 2, it downsizes it to regular quality (like 1400x1200 ish). Since I don't yet own an iPad 3, do the images stay HD quality when an ibook (from ibooks author) is viewed on an iPad 3?

    Okay, I just finished building my Ibook in Ibooks Author. I tested one of the free ibooks (Peter Rabit) and liked how it reads to you. I have read many articles and other posts here on Apple.com and everyone seems to want to add this read aloud feature. I have the Fixed Layout EPUBs Miniguide and iBookstore Asse Guide 4_8 and even though the miniguide explains things step by step, its like reading Greek. I am new to programming. Since I assume you are an expert, what I need is help getting started. I'm pretty good at figuring things out, I just need to get a jumpstart as fast as possible. (I don't want to spend a whole month trying to add this read aloud feature).
    1. I have a finished book but its not looking like the fixed layout kids books I see on ibooks. Is there a simple way to just tell ibooks its a fixed layout and get rid of the textbook features without using programming? (I know there are people out there who agree with me)
    2. I know that I need a XML SMIL compatable text editor (BBedit is the only one I heard is free and good). But where do I begin? Is there some kind of template of code where I just add in the code to get the book to read from audio files? If I edit the epub file, will this book still be able to be sent to the iPad through ibooks Author for a preview?
    3. I am familiar with Audacity so the audio part is doable. But the coding is scaring me. To add a word by word reading for the ibook requires more programming.
    4. Tell me a short list of what I need to do in order. I have all this information but its overwhelming because I hate programming. (I tried making an iphone app and gave up because it required Xcode, which is way out of my league). I don't know where to start from my finished iBook so what is the next thing I need to do?
    Thanks Jessica

  • Layout Set: How to add a new field in a layout Set?

    Hi ABAPPERS.
    Question:
    How can I add a new field in a layout set?
    Scenario:
    QC21 uses a global Layout Set ZQMECOA_GLOBAL.
    There's a field required in this Layout Set which is Production Date(CAUFVD-GLTRP).
    Where is the date query happening here?
    Where can I insert the SELECT statement for the new field required?
    I try to look at:
    OPEN_FORM and WRITE_FORM, it seems that date query or SELECTION of data is not happening here.
    Thanks.

    If you are adding a header field then you will extend the header structure in CRM and do the same with Item structures for Item fields. You will use EEWB or similar technique in the CRM backend to extend the header or item.
    These extended fields in the backed are available in customer_h or _i structures in the order object that can be read and modified in the Header BAdI or Item BAdi.
    If you think that this message is cryptic or not enough, then you should search for Extension Guide in this forum and read the document.

  • HT201436 There is no +, close to my contact button...How can i add contacts to my i phone?

    There is no + button close to the contact button. How can i add contacts to mu i-phone 4S?

    Hi Friend,
    Check if you turned Restrictions on before, in Settings>>General>>Restrictions.
    Hope it helps

  • I need help, How could I add Aliases to Local Administrator account via terminal commands???

    I need help, How could I add Aliases to Local Administrator account via terminal commands???
    I want to use commands to add alias for existing administrator account remotly by using ARD.
    Thanks.

    Hi,
    a Windows Domain Controller does not have any local user or groups. So you might add the user to the admin group at Domain level.
    B RGDS,
    Gregor
    Edited by: Gregor Gasper on Jan 9, 2009 1:44 PM

  • How to add a close button to a edge animation ?

    How to add a close button to a edge animation ?

    Welcome to our community, Laurie
    You posted this in the FlashHelp section. Is that your actual
    output type? If so, you will need to make edits to the FlashHelp
    using Adobe Flash.
    Cheers... Rick

  • How can I add voice command to IPad 2?

    How do I add voice command to my iPad 2?

    I think you are referring to Voice Over.  See this:
    http://www.apple.com/accessibility/ipad/vision.html
    Also check out the Voice Over section of the iPad User Manual:
    iPad and iPad mini User Guide (For iOS 6.1 Software)

  • How do I add a new worksheet to an excell file utilizing a template with the report generation toolkit?

    Hello,
    My vi is gathering data from a piece of machinery. At varrious points durring the process, my vi must create printable reports. I am using the report generation tool kit to do this. What I want to do is for every report generated durring the run, add it as a new worksheet in an Excell workbook. My excell template works fine for the initial master report and I can add new data to new worksheets. What I am having a problem figuring out is how do I add the new data to a new worksheet using an excel template? I have 5 different reports that need to be generated at different times with some more often than others. I would like all these reports to be in the
    same master excel file. Thanks in advance
    -Greg
    Gregory Osenbach, CLA
    Fluke

    Hi Greg,
    There is no built-in support in LabVIEW to add a new worksheet to an existing Excel report simply because this functionality does not exist in the Excel application itself.
    My suggestion would be to open up the template you wish to use for the new worksheet. Copy the cells from the template and paste them into your new worksheet that you've created. Then close the original template and you have another copy of the template in which you can populate with data values.
    I have attached an example program of how to Copy and Paste a Cell in Microsoft 97 Using ActiveX in LabVIEW to this post. Hope this helps!
    Kileen C.
    Applications Engineer
    National Instruments
    Attachments:
    XL_cell_copy_and_paste.llb ‏76 KB

  • How do you add multiple iTunes to Keynote

    How do you add multiple songs from the iTunes to your Keynote presentation?

    Jer&Renee,
    welcome to Apple Discussions.
    It depends where you want them in your presentation.
    Open the Media inspector and choose a playlist. In the list of entries, mark those you want to add to Keynote (use command-click to mark multiple titles not in one block).
    Then drag the marked titles either on a slide or on the small Audio field (looks like a frame) in Document inspector. When you then hover the cursor at the Audio "frame", you'll see the quick info "Multiple Files". You cannot change the order or remove one of the files, but only all of them.

  • How can i  add more than 500 jPanels in a jScrollPane

    Hello to all ,
    I am facing a problem related to adding jPanels in jScrollPane. My application needs more than 500 jpanels in the jscrollpane.where in each jPanel 4 jtextboxes, 1 comboboxes, 1 check box is there.when the check box will be clicked then the total row( ie row means the panel containing the 4 jtextboxes, 1 comboboxes, 1 check box ).and when the user will click on move up or move down button then the selected jpanel will move up or down.
    The tool(sun java studio enterprise 8.1) is not allowing more Jpanels to add manually. so i have to add the jpanels by writing the code in to a loop. and the problem is that when i am trying to add the code in the code generated by the tool the code written out side the code by me is not integratable into the tool generated code.
    If u watch the code here am sending u ll get what am facing the problem. The idea of creating jpanels through loop is ok but when trying to impleent in tool facing difficulties.
    A example code am sending here. please tell me how i can add more panels to the scrollpane(it is the tool generated code)
    Thanks in advance , plz help me for the above
    package looptest;
    public class loopframe extends javax.swing.JFrame {
    /** Creates new form loopframe */
    public loopframe() {
    initComponents();
    private void initComponents() {
    jScrollPane1 = new javax.swing.JScrollPane();
    jPanel1 = new javax.swing.JPanel();
    jPanel2 = new javax.swing.JPanel();
    jTextField1 = new javax.swing.JTextField();
    jComboBox1 = new javax.swing.JComboBox();
    jPanel3 = new javax.swing.JPanel();
    jTextField2 = new javax.swing.JTextField();
    jComboBox2 = new javax.swing.JComboBox();
    setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
    jTextField1.setText("jTextField1");
    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    org.jdesktop.layout.GroupLayout jPanel2Layout = new org.jdesktop.layout.GroupLayout(jPanel2);
    jPanel2.setLayout(jPanel2Layout);
    jPanel2Layout.setHorizontalGroup(
    jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel2Layout.createSequentialGroup()
    .add(28, 28, 28)
    .add(jTextField1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 109, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(54, 54, 54)
    .add(jComboBox1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 156, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .addContainerGap(35, Short.MAX_VALUE))
    jPanel2Layout.setVerticalGroup(
    jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel2Layout.createSequentialGroup()
    .addContainerGap()
    .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
    .add(jTextField1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(jComboBox1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .addContainerGap(21, Short.MAX_VALUE))
    jTextField2.setText("jTextField2");
    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
    org.jdesktop.layout.GroupLayout jPanel3Layout = new org.jdesktop.layout.GroupLayout(jPanel3);
    jPanel3.setLayout(jPanel3Layout);
    jPanel3Layout.setHorizontalGroup(
    jPanel3Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel3Layout.createSequentialGroup()
    .add(20, 20, 20)
    .add(jTextField2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 111, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(33, 33, 33)
    .add(jComboBox2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 168, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .addContainerGap(40, Short.MAX_VALUE))
    jPanel3Layout.setVerticalGroup(
    jPanel3Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel3Layout.createSequentialGroup()
    .add(21, 21, 21)
    .add(jPanel3Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
    .add(jComboBox2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(jTextField2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .addContainerGap(21, Short.MAX_VALUE))
    org.jdesktop.layout.GroupLayout jPanel1Layout = new org.jdesktop.layout.GroupLayout(jPanel1);
    jPanel1.setLayout(jPanel1Layout);
    jPanel1Layout.setHorizontalGroup(
    jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel1Layout.createSequentialGroup()
    .addContainerGap()
    .add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(jPanel3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
    .addContainerGap(58, Short.MAX_VALUE))
    jPanel1Layout.setVerticalGroup(
    jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(jPanel1Layout.createSequentialGroup()
    .add(21, 21, 21)
    .add(jPanel2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .add(49, 49, 49)
    .add(jPanel3, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .addContainerGap(66, Short.MAX_VALUE))
    jScrollPane1.setViewportView(jPanel1);
    org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
    getContentPane().setLayout(layout);
    layout.setHorizontalGroup(
    layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(layout.createSequentialGroup()
    .add(31, 31, 31)
    .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 439, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .addContainerGap(74, Short.MAX_VALUE))
    layout.setVerticalGroup(
    layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
    .add(layout.createSequentialGroup()
    .add(30, 30, 30)
    .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 254, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
    .addContainerGap(55, Short.MAX_VALUE))
    pack();
    }// </editor-fold>
    * @param args the command line arguments
    public static void main(String args[]) {
    java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
    new loopframe().setVisible(true);
    // Variables declaration - do not modify
    private javax.swing.JComboBox jComboBox1;
    private javax.swing.JComboBox jComboBox2;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JTextField jTextField1;
    private javax.swing.JTextField jTextField2;
    // End of variables declaration
    and
    package looptest;
    public class Main {
    public Main() {
    public static void main(String[] args) {
    new loopframe().setVisible(true);
    }

    Thanks for here kind attention to solve my problem.
    I am thinking to create the classes separately for the components (i.e the jpanel, combobox,textbox etc)and call their instaces from the for loop .But the problem is the jpanel will contain the other components and that jpanels (unlimited jpanels will be added later)will be later added to the jscrollpane.
    By writing code, the problem is to place components( the comboboxes,textboxes etc placed on the jpanel ) in appropriate coordinates . So i am doing it through tool .
    I am sending here the sample code related to my actual need . In this i have taken a jScrollPane, on that i have added jPanel1 and on jPanel1 i have added jPanel2.On jPanel2 jTextField1, jComboBox1,jCheckBox are added. If the u ll see the code u can understand what problem i am facing.
    If i am still not clearly explained ,please ask me. plz help me if u can as u have already handled a problem similar to this.
    package addpanels;
    public class Main {
    /** Creates a new instance of Main */
        public Main() {
        public static void main(String[] args) {
            new addpanels().setVisible(true);
    } and
    package addpanels;
    public class addpanels extends javax.swing.JFrame {
        /** Creates new form addpanels */
        public addpanels() {
            initComponents();
        private void initComponents() {
            jScrollPane1 = new javax.swing.JScrollPane();
            jPanel1 = new javax.swing.JPanel();
            jPanel2 = new javax.swing.JPanel();
            jTextField1 = new javax.swing.JTextField();
            jComboBox1 = new javax.swing.JComboBox();
            jCheckBox1 = new javax.swing.JCheckBox();
            setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
            jTextField1.setText("jTextField1");
            jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
            jCheckBox1.setText("jCheckBox1");
            jCheckBox1.setBorder(javax.swing.BorderFactory.createEmptyBorder(0, 0, 0, 0));
            jCheckBox1.setMargin(new java.awt.Insets(0, 0, 0, 0));
            org.jdesktop.layout.GroupLayout jPanel2Layout = new org.jdesktop.layout.GroupLayout(jPanel2);
            jPanel2.setLayout(jPanel2Layout);
            jPanel2Layout.setHorizontalGroup(
                jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(jPanel2Layout.createSequentialGroup()
                    .addContainerGap()
                    .add(jTextField1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 131, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                    .add(jComboBox1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 144, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                    .add(jCheckBox1)
                    .addContainerGap(39, Short.MAX_VALUE))
            jPanel2Layout.setVerticalGroup(
                jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel2Layout.createSequentialGroup()
                    .addContainerGap(17, Short.MAX_VALUE)
                    .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                        .add(jTextField1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .add(jComboBox1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .add(jCheckBox1))
                    .addContainerGap())
            org.jdesktop.layout.GroupLayout jPanel1Layout = new org.jdesktop.layout.GroupLayout(jPanel1);
            jPanel1.setLayout(jPanel1Layout);
            jPanel1Layout.setHorizontalGroup(
                jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(jPanel1Layout.createSequentialGroup()
                    .addContainerGap()
                    .add(jPanel2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(34, Short.MAX_VALUE))
            jPanel1Layout.setVerticalGroup(
                jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(jPanel1Layout.createSequentialGroup()
                    .add(26, 26, 26)
                    .add(jPanel2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(152, Short.MAX_VALUE))
            jScrollPane1.setViewportView(jPanel1);
            org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane());
            getContentPane().setLayout(layout);
            layout.setHorizontalGroup(
                layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup()
                    .addContainerGap(36, Short.MAX_VALUE)
                    .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 449, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(18, 18, 18))
            layout.setVerticalGroup(
                layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                .add(layout.createSequentialGroup()
                    .add(32, 32, 32)
                    .add(jScrollPane1, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 230, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(38, Short.MAX_VALUE))
            pack();
        public static void main(String args[]) {
            java.awt.EventQueue.invokeLater(new Runnable() {
                public void run() {
                    new addpanels().setVisible(true);
        // Variables declaration - do not modify//GEN-BEGIN:variables
        private javax.swing.JCheckBox jCheckBox1;
        private javax.swing.JComboBox jComboBox1;
        private javax.swing.JPanel jPanel1;
        private javax.swing.JPanel jPanel2;
        private javax.swing.JScrollPane jScrollPane1;
        private javax.swing.JTextField jTextField1;
        // End of variables declaration//GEN-END:variables
    }

Maybe you are looking for