|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
passing an array between formsdoes anyone know how to pass an array between forms ? I tried .... --- FORM 1 --- Public Array(2) As byte Array(0) = 1 Array(1) = 5 Public HowMany As byte = 2 Dim NextForm As New Form NextForm.Array = Array NextForm.HowMany = HowMany NextForm.Show() --- FORM 2 --- Public Array() As byte Public HowMany As byte Redim preserve Array(HowMany) MessageBox.show (Array(1)) ..... but it doesn't work ... Thanx John well there are lots of ways
delcare the array in a mod class so every form has access to it make the array public Make the array a property depends on what your trying to do Show quoteHide quote "John Devlon" <johndev***@hotmail.com> wrote in message news:ctW6e.63368$u32.4607085@phobos.telenet-ops.be... > > Hi, > > does anyone know how to pass an array between forms ? > > I tried .... > > --- FORM 1 --- > > Public Array(2) As byte > Array(0) = 1 > Array(1) = 5 > Public HowMany As byte = 2 > > Dim NextForm As New Form > NextForm.Array = Array > NextForm.HowMany = HowMany > NextForm.Show() > > > --- FORM 2 --- > Public Array() As byte > Public HowMany As byte > > Redim preserve Array(HowMany) > > MessageBox.show (Array(1)) > > > .... but it doesn't work ... > > > Thanx > > John > > >
Translate C# to VB.net?
Splash window XmlTextReader not getting all Elements "Add Reference" hosed--doesn't display the dialog in VS.NET Combobox and DataSource PDF to Picturebox Newbie: substrings VB.net Datagrid Parent Row [ANN] April 12, 2005, "Visual Basic 2005 Language Enhancements" chat ComboBox data |
|||||||||||||||||||||||