Is it possible in ASP.NET to dynamically load up a WebControl from a string with some tag contents in it (without writing a bunch of custom code)?
For instance, I have a string like the following:
string controlTag = "<asp:Label ID=\"lblLabel\" runat=\"server\" />";
I then want to do something like the following to load up the control from that string:
WebControl webControl = LoadControlFromTagString(controlTag);
I can simply parse the string myself and dynamically load up a control in LoadControlFromTagString, but I was wondering if there is anything built in to .NET I can take advantage of. Any suggestions?