Last post Feb 28, 2007 08:50 PM by simmohall
Feb 27, 2007 06:35 PM|simmohall|LINK
Just wondering if it is possible to have design-time shared user controls. E.g. I have followed the process to setup a 'base' web project that contains a number of shared user controls and configured IIS. I then use these user controls in a number of
web application projects. This works fine as per
http://support.microsoft.com/kb/825996. However the limitation is that you need to code the registering and using of the user controls rather than drag and drop.
I want to know if it is possible to add these user controls(through vss sharing) to each web app project so to enable you to drag and drop. When i try i get the error...
"Parser Error Message: The type 'MT.Web.GlobalShared.Controls.DatePickerLite' is ambiguous: it could come from assembly 'C:\dev\MT\2.0\VCR\MT.VCR\MT.VCR.Web\MT.VCR.Web\bin\MT.VCR.Web.DLL' or from assembly 'C:\dev\MT\2.0\VCR\MT.VCR\MT.VCR.Web\MT.VCR.Web\bin\MT.Web.DLL'.
Please specify the assembly explicitly in the type name."
which makes sense as there are obviously now 2 dll's using the same namespace.
Is it possible to set this up or do our developers need to hand code this.
Feb 27, 2007 09:20 PM|jminond|LINK
You could put your user controls in the GAC is one option.
If you do not want to make server controls, and you want design support, you can make a web app project of user controls, and pre compile using web deployment or aspnet merge to create a single or multiples, whatever, and then put those in your gac.
then you can have one top level config in the root of the site, and the referenced assemblies will be known to all applications. you can also install the dll in vs.net and get the controls on the toolbar.
lots of options.
another is to create a junction folder of your user controls in each application, and then they are "physically" there in each application. this has many pros and cons, mainly difficult to maintian, and control, but it works well if you want it.
Feb 28, 2007 08:50 PM|simmohall|LINK