F
Fabio
Hi all,
look this code, why the InvalidCastException are raised?
How to workaround it?
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Dim Label2 As New Windows.Forms.Label
Dim Label3 As New New_Label
Label2.Text = "TEST"
Label3 = Label2
End Sub
Public Class New_Label
Inherits Windows.Forms.Label
End Class
Thaks in advance
look this code, why the InvalidCastException are raised?
How to workaround it?
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Dim Label2 As New Windows.Forms.Label
Dim Label3 As New New_Label
Label2.Text = "TEST"
Label3 = Label2
End Sub
Public Class New_Label
Inherits Windows.Forms.Label
End Class
Thaks in advance