A
Academia
Public Class Some(Of t)
Inherits System.Windows.Forms.UserControl
....
DirectCast(ListBox1.Items(ListBox1.SelectedIndex), t).xyz = TextBox1.Text
....
TextBox1.Text = DirectCast(ListBox1.SelectedItem, t).xyz
At edit time the above statements produce an error that xyz is not a member
of t.
It works OK if instead of genetics I use, in place of t, an actual type that
has an xyz property.
How should I do this with generics?
thanks
Inherits System.Windows.Forms.UserControl
....
DirectCast(ListBox1.Items(ListBox1.SelectedIndex), t).xyz = TextBox1.Text
....
TextBox1.Text = DirectCast(ListBox1.SelectedItem, t).xyz
At edit time the above statements produce an error that xyz is not a member
of t.
It works OK if instead of genetics I use, in place of t, an actual type that
has an xyz property.
How should I do this with generics?
thanks