a java quesion: JFrame arrays

This is a discussion on a java quesion: JFrame arrays within the A Brief History of Cprogramming.com forums, part of the Community Boards category; how do i declare them? i tried JFrame aList[] = new JFrame(); and it didn;t work, searched and looked @ ...

  1. #1
    Registered User Commander's Avatar
    Join Date
    Sep 2001
    Posts
    804

    a java quesion: JFrame arrays

    how do i declare them? i tried

    JFrame aList[] = new JFrame();

    and it didn;t work, searched and looked @ the API doc with little/no help. any ideas?
    oh i'm sorry! i didn;t realize my fist was rushing to meet ur face!

    MSN :: commander_android@hotmail.com []*[]

  2. #2
    Crazy Fool Perspective's Avatar
    Join Date
    Jan 2003
    Location
    Canada
    Posts
    2,640
    JFrame aList[] = new JFrame[SIZE];

    or

    JFrame [] aList = new JFrame[SIZE];

  3. #3
    Registered User Commander's Avatar
    Join Date
    Sep 2001
    Posts
    804
    i have to define a size???? stupid project!
    thankx pers
    oh i'm sorry! i didn;t realize my fist was rushing to meet ur face!

    MSN :: commander_android@hotmail.com []*[]

  4. #4
    Crazy Fool Perspective's Avatar
    Join Date
    Jan 2003
    Location
    Canada
    Posts
    2,640
    Originally posted by Commander
    i have to define a size???? stupid project!
    thankx pers
    yeah, the size of the array. if you want it to be dynamic then store the JFrame's in a vector as they are created.

  5. #5
    jman
    Guest
    the vector class is obsolete

  6. #6
    Crazy Fool Perspective's Avatar
    Join Date
    Jan 2003
    Location
    Canada
    Posts
    2,640
    Originally posted by jman
    the vector class is obsolete
    erm, java.util.Vector is not obsolete.

  7. #7
    Registered User Commander's Avatar
    Join Date
    Sep 2001
    Posts
    804
    thanx 4 the vector tip pers.
    appreciate it
    oh i'm sorry! i didn;t realize my fist was rushing to meet ur face!

    MSN :: commander_android@hotmail.com []*[]

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need Help With 3 Parallel Arrays Selction Sort
    By slickwilly440 in forum C++ Programming
    Replies: 4
    Last Post: 11-19-2005, 10:47 PM
  2. C#, Java, C++
    By incognito in forum A Brief History of Cprogramming.com
    Replies: 10
    Last Post: 10-05-2004, 03:06 PM
  3. Beginning Java 2d Arrays
    By Hexxx in forum Tech Board
    Replies: 4
    Last Post: 05-28-2004, 07:12 PM
  4. Java woes
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 07-06-2003, 01:37 AM
  5. Crazy memory problem with arrays
    By fusikon in forum C++ Programming
    Replies: 9
    Last Post: 01-15-2003, 09:24 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21