Results 1 to 1 of 1
  1. #1
    taurus22 is offline Member
    Join Date
    Sep 2014
    Posts
    10
    Rep Power
    0

    Default How to put a number with loop into checkbox

    Hey guys,
    I want all years between 1900 and 2014 into a cbx.
    i tried this but it doesn't work

    Java Code:
    int year=1900;
    while(year<2014)
    {
    cbxYear.addItem(year + 1);
    year = year + 1;
    }
    Thank you in advance

    Oh i found the mistake i had wrote the code into the button :D :)
    Last edited by taurus22; 09-07-2014 at 05:18 PM.

Similar Threads

  1. Help loop to decide even or odd number !?
    By madnomad in forum New To Java
    Replies: 7
    Last Post: 06-22-2013, 11:46 AM
  2. CheckBox Program Install Loop
    By Mike80 in forum New To Java
    Replies: 3
    Last Post: 01-14-2013, 10:01 AM
  3. Generate Random Number Loop
    By saber210 in forum New To Java
    Replies: 9
    Last Post: 08-12-2011, 05:49 PM
  4. Loop through all letter and number possibilities?
    By Mr.abe90 in forum New To Java
    Replies: 11
    Last Post: 05-29-2011, 08:47 PM
  5. Replies: 3
    Last Post: 07-27-2010, 10:52 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
  •