Thread: a java quesion: JFrame arrays

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

    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 :: [email protected] []*[]

  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
    801
    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 :: [email protected] []*[]

  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
    801
    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 :: [email protected] []*[]

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, 02:06 PM
  3. Beginning Java 2d Arrays
    By Hexxx in forum Tech Board
    Replies: 4
    Last Post: 05-28-2004, 06:12 PM
  4. Java woes
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 07-06-2003, 12:37 AM
  5. Crazy memory problem with arrays
    By fusikon in forum C++ Programming
    Replies: 9
    Last Post: 01-15-2003, 09:24 PM