Visual Studio requires that designers use the first class the the file.

  • Thread starter Thread starter qwert
  • Start date Start date
Q

qwert

Hello,

when creating a user control with Visual Basic .NET (v2.0), I get the error:
"Visual Studio requires that designers use the first class the the file."
when I try it view it in Design mode. There is only one class in the file,
the user control.

The first line is "Namespace MyStuff". When I remove this line, all is well
and I can view the control in Design mode.

How do I put the user control in a namespace and still be able to use Design
mode? Not all the classes in the assembly are in the same namespace, so
setting the project properties won't do.

Thanks for any help.
 
Nevermind,

have to update a file "controlname.Designer.vb". There's a partial class in
it that has to be in the same namespace,

Thanks.
 
Back
Top