Introduction- Syntax of Register Directive for the custom control.

The @Register Directive is a directive used to register user defined controls on a web page and it creates an association between a TagPrefix and a Custom control ,which provides developers with a concise way to refer to custom controls in an application file.

The < %@Register % > directive take a slightly different syntax for custom control.

Syntax:-  <%@ Register TagPrefix="PCS" Namespace="PCSCustomWebControls"  Assembly="PCSCustomWebControl" %>

You use the TagPrefix option in this syntax because Custom Control Assembly you use may contain several custom controls and each of these will be named by Class . So TagName is Redundant. In this code, we use the TagPrefix PCS and use the Assembly "PCSCustomWebControls.dll" with controls in "PCSCustomWebControls" Namespace.

If you have a Control called ButtonControl in this Namespace ,you could use it with the ASP.NET code.
For example: <PCS: ButonControl  Runat = "Server"  ID="MyButtonControl" />