Question is it possible to have a .ashx or webservice return a user control rendered? if so how would i do this?
Adding a User Control to a PageYou add a user control to a page by registering it on the host page. When you register it, you specify the . ascx file that contains the user control, a tag prefix, and a tag name that you will use to declare the user control on the page.
Web user controls are derived from System. Web. UI. UserControl namespace. These controls once created, can be added to the aspx page either at design time or programmatically during run time.
UserControl : A control which can reuse the Components in the Applications. The control can be defined in both Xaml and Code-Behind. CustomControl : An UserInterface element that have a distinct behavior which is said as CustomControl.
This post from our beloved Scottgu might help you :)
I haven't tried this, but you might be able to do this by calling the RenderControl method.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With