Type.GetType("System.Web.UI....)

T

TR

Is it possible to use Type.GetType(...) with the types in the
System.Web.UI.? My attempts always resolve to Nothing.

Is this legal, or is the Web.UI assembly of the kind Type.GetType doesn't
work with?
Type.GetType("System.Web.UI.WebControls.TextBox", False, True)

Thanks
TR
 
M

Mythran

TR said:
Is it possible to use Type.GetType(...) with the types in the
System.Web.UI.? My attempts always resolve to Nothing.

Is this legal, or is the Web.UI assembly of the kind Type.GetType doesn't
work with?
Type.GetType("System.Web.UI.WebControls.TextBox", False, True)

Thanks
TR

Why not GetType(System.Web.UI.WebControls.TextBox)? Do you have to pass it
a string?

Mythran
 
T

TR

Mythran,
I'm trying to write a generic routine to find all controls of a specified
type. But even so, if I do what you suggest, I get the error that
Checkbox|TextBox|etc "is a type in 'WebControls' and cannot be used as an
expression".
Regards
TR
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,234
Latest member
SkyeWeems

Latest Threads

Top