When we use Custom Control?When we use User Control? What is difference between these two?

When we use Custom Control?When we use User Control? What is difference between these two?
================================================================


1. You create a Custom control when it is going to be used across different applications
2. Custom controls don't a visual interface.
----------------------------------------------------
3. Custom controls however can be added to your tool box and used in different applications without re-compiling.
4. It's a .dll
=================
User Control

1. If the control you are going to create is only for a particular website then User Control is the best option
2. User controls have a visual interface
-----------------------------------------------
3.User control will not appear in tool box and it will not have design support and loaded at runtime.
4. It's an .ascx

====================================================================

WebUser Control:
1) It has to be provided within a special file called .ascx file
2) It is not a pre-compiled code
3)this will not appear on the ToolBox
4) It is Local to a particular application
5) it supports caching

Custom Control:
1) It has to be provided within .DLL file
2) it is a pre-compiled code
3) this will be appeared on the ToolBox
4) It is global to all the application
5)It doesn't support caching


Comments

Author: Gaurav Aroraa26 Oct 2008 Member Level: Gold   Points : 1

Hi Kumar,

A nice article. But try to explore more descriptive with examples. As you have posted this in Article section.

Thanks & regards,
Gaurav Arora



  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: