Implementing asp.net user management

I am using VS 2010. Is there a way to "expand" the user control and encode it as a binary (.ocx like) way so that I can just reference it from other projects and the html / code behind cannot be edited?

+4
source share
3 answers

No, you either cut and paste, or look at user server controls. Server user controls are basically a way to create the same .ascx controls, but all this is done in code without a part of the user interface. If done correctly, you can still have a drag and drop UI for your controls.

http://msdn.microsoft.com/en-us/library/zt27tfhy(v=vs.100).aspx

+1
source

As ps2goat says, you want to configure server controls. However, there is a way to create them from standard ascx controls with only some extra effort.

http://msdn.microsoft.com/en-us/library/aa479318.aspx

+1
source

This should be possible (although not recommended) if you put the .NET code in ASCX markup inside the <script runat="server"></script> .

0
source

Source: https://habr.com/ru/post/1494140/


All Articles