I'm working with referencing user controls on my ASPX page and I'm wondering what the difference is between these two page directives.
ASP.NET @Register vs. @Reference
asp.netpage-directives
Related Topic
- C# – How to create a dropdownlist from an enum in ASP.NET MVC
- .net – ASP.NET Web Site or ASP.NET Web Application
- Javascript – Change the selected value of a drop-down list with jQuery
- C# – In C#, what is the difference between public, private, protected, and having no access modifier
- Asp.net-mvc – ASP.NET MVC – Set custom IIdentity or IPrincipal
- R – ASP.NET – Placement of @ Register directive
- C# – The request was aborted: Could not create SSL/TLS secure channel
- Asp.net-mvc – Difference Between ViewResult() and ActionResult()
Best Answer
@Register
is primarily used for registering tag prefixes to declaratively use controls within a page.@Reference
is primarily used to refer to a page or user control (by file name or virtual path) to programatically refer to members of the page or control.