Add validation at run time?

dprintingmxss

New Member
Is it possible to add validation controls to a page at run time? I'm getting the error message that it must be placed in a form tag with runat="server". When adding controls at run time there doesn't seem to be a way to add the runat="server".How are you trying to load the control at runtime? To load a control at runtime you should be using the LoadControl method. Are you doing something different?Use the palceholder tag and add controls to it at runtime - there some examples in the Sam's learn asp.net in 21 days book. You can also use the panel control to "hide" panels of controls then enable them at runtime if that's easier.
 
Back
Top