Arrays of controls

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Geoff Turner

    Arrays of controls

    Hello all,
    It is possible, in VB6, to have a two dimentional array of controls?
    ie Label(0,0), Label(0,1) etc?

    I seem to recall doing something like this years ago with VB3 where
    I have an array of frames and each frame had an array of labels.
    This made addressing simular to a 2D array thus:
    Frame(0).Label( 0)
    Frame(0).Label( 1)
    ....
    Frame(x).Label( y)

    But, alas, maybe I was dreaming because I can't get it
    to work in VB3 now!

    Any ideas?

    Thanks
    Geoff Turner.


  • J French

    #2
    Re: Arrays of controls

    On Wed, 1 Oct 2003 08:48:31 +0100, "Geoff Turner"
    <g.s.turner@rl. ac.uk> wrote:
    [color=blue]
    >Hello all,
    >It is possible, in VB6, to have a two dimentional array of controls?
    >ie Label(0,0), Label(0,1) etc?[/color]

    Yes - it is not a 'control array'

    More of an 'aliasing' of other controls in an Array eg:

    Set lblItem( 5, 6 ) = lblArray( 2 )
    [color=blue]
    >
    >I seem to recall doing something like this years ago with VB3 where
    >I have an array of frames and each frame had an array of labels.
    >This made addressing simular to a 2D array thus:
    >Frame(0).Label (0)
    >Frame(0).Label (1)
    >...
    >Frame(x).Label (y)
    >
    >But, alas, maybe I was dreaming because I can't get it
    >to work in VB3 now!
    >
    >Any ideas?
    >
    >Thanks
    >Geoff Turner.
    >
    >[/color]

    Comment

    • Geoff Turner

      #3
      Re: Arrays of controls


      "J French" <erewhon@nowher e.com> wrote in message
      news:3f7a8ca2.7 [email protected] lick.com...[color=blue]
      > On Wed, 1 Oct 2003 08:48:31 +0100, "Geoff Turner"
      > <g.s.turner@rl. ac.uk> wrote:
      >[color=green]
      > >Hello all,
      > >It is possible, in VB6, to have a two dimentional array of controls?
      > >ie Label(0,0), Label(0,1) etc?[/color]
      >
      > Yes - it is not a 'control array'
      >
      > More of an 'aliasing' of other controls in an Array eg:
      >
      > Set lblItem( 5, 6 ) = lblArray( 2 )
      >[color=green]
      > >
      > >I seem to recall doing something like this years ago with VB3 where
      > >I have an array of frames and each frame had an array of labels.
      > >This made addressing simular to a 2D array thus:
      > >Frame(0).Label (0)
      > >Frame(0).Label (1)
      > >...
      > >Frame(x).Label (y)
      > >
      > >But, alas, maybe I was dreaming because I can't get it
      > >to work in VB3 now!
      > >
      > >Any ideas?
      > >
      > >Thanks
      > >Geoff Turner.
      > >
      > >[/color]
      >[/color]

      Thanks very much. Just the job.

      Geoff


      Comment

      Working...