Thread: web control
View Single Post
Old 09-28-2004, 05:58 AM   #3 (permalink)
rdove
Masked Moderator
 
rdove's Avatar
 
Join Date: May 2002
Location: Indianapolis, IN
Posts: 260
rdove is on a distinguished road
A web control is a textbox, label, button, etc... that can be used in your ASPX pages.

A user control can be added to your project and reused many times. Think of it like Server Side Includes, but with more functionality. For example if you have 2 text boxes and 1 button that you are going to use in your web app repeatedly, the functionality of the form is going to be the same, you could create a user control and add the control to your form instead coding it over and over. You can also create your own custom controls like a graphing tool for example and use it in your project.

Now, one you didn't mention is a Web Custom Control. A Web Custom Control is essentially a user control, but you can use it across multiple applications effortlessly. With a user control you can use it in multiple applications, but you have to add the control to every project you want to use it in. With a Web Custom Control you can assign it a Strong Name and add it to the Global Cache Assembly (GAC). By doing this you can just add a reference to it and you do not have to compile the control with your code. Also, you can add Web Custom Controls to the VS.NET Server Explorer box for ease of use.
__________________
~Ryan

rdove is offline   Reply With Quote