|
Then you need Form1.[name of control].MyLabel.Caption = "hello"
What VB is trying to do is reference the class rather than the instance on a form, which can't be done.
Let's say I had a usercontrol called ctlMyWidget. The default name for the control when I put it on a form would be ctlMyWidget1. As you're using UserControl1 for the class name, the default name is actually UserControl11 , which is where the problem is.
|