Results 1 to 3 of 3

Thread: combobox

  1. #1
    leader is offline Member
    Join Date
    Feb 2011
    Posts
    2
    Rep Power
    0

    Unhappy combobox

    i have two comboboxs
    how can i make this work i tried a lot but i couldn't :(:(:(:(
    if i select item "A" so it should be removed from other combobox
    combobox combobox2
    A B
    B C
    C

    COULD YOU PLEASE HELP ME :(

  2. #2
    baloda is offline Member
    Join Date
    Nov 2010
    Location
    New Delhi
    Posts
    50
    Rep Power
    0

    Default

    can u put ur code here???
    other wise who will provide u the whole code.

  3. #3
    leader is offline Member
    Join Date
    Feb 2011
    Posts
    2
    Rep Power
    0

    Default

    here is the code
    jComboBox1 = new javax.swing.JComboBox();
    jComboBox2 = new javax.swing.JComboBox();

    setDefaultCloseOperation(javax.swing.WindowConstan ts.EXIT_ON_CLOSE);

    jComboBox1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "A", "B", "C" }));
    jComboBox1.addActionListener(new java.awt.event.ActionListener() {
    public void actionPerformed(java.awt.event.ActionEvent evt) {
    jComboBox1ActionPerformed(evt);
    }
    });

    jComboBox2.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "A", "B", "C" }));

Similar Threads

  1. Input box with combobox within
    By cowboy in forum New To Java
    Replies: 4
    Last Post: 10-23-2009, 03:07 PM
  2. problem in combobox
    By 435.mahesh in forum AWT / Swing
    Replies: 3
    Last Post: 05-04-2009, 06:12 AM
  3. Need Help combobox
    By kwink in forum AWT / Swing
    Replies: 3
    Last Post: 03-21-2009, 11:05 AM
  4. combobox
    By chandu.v in forum New To Java
    Replies: 2
    Last Post: 07-02-2008, 09:36 PM
  5. ComboBox Fix Width
    By Azndaddy in forum New To Java
    Replies: 2
    Last Post: 05-29-2008, 05:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •