Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Web.config issueWeb.config issue
Previous
 
Next
New Post
1/6/2011 8:23 AM
 
After more research I found that installing Telerik controls and using the Telerik | Convert to Telerik project adds a local web.config file to the module folder that contains the Telerik tag prefix.   Having multiple web.config files causes other problems as detailed in one of my posts here.

The solution is to delete the addtional local web.config files and add a register directive to each page that uses the controls.

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

What I don't understand is why the VS designer does not pick up the web.config tag prefix defined in the DNN virtual directory's web.config
 
New Post
1/6/2011 9:06 AM
 
I also found that after adding a new page and starting a debug session I get a dialog that when confirmed generates and adds 3 web.config files to the project to enable debugging.  I believe this and the Telerik project setting generated the additional web.config files that have been causing headaches for me.

I can't add a screen shot of the DLL here but it says:  The current page can not be run in debug mode because debugging is not enabled in the web.config file.

Once again I fund the web.config file in the virtual folder has debug mode set to True but it isn't being picked up by VS.  It seems that VS wants to have a local web.config file and IIS doesn't like it.

<system.web>
        <compilation debug="true" >

 
New Post
1/6/2011 1:00 PM
 

I have found a solution!  I needed to change the way my solution is organized and create a Startup Project in the DNNDev virtual folder.  That way the default web.config file IS the default project web.config file for debugging.  I hope this helps someone else and would suggest my solution structure might be added to the DNN FAQ

The web.config file is associated with the project and there cannot be multiple web.config files.  It must be in the same project folder that the VS project is in for debugging.   What is needed is a VS project at the virtual folder level.   VS 2010 now also supports multiple web.config files and  in the project based upon configuration, release, debug, etc. 

 So, the solution is to create or copy a VS project to the virtual folder and set it as the Start Up Project.  Copy your existing web.config to the configuration files as below and add a new Web Configuration item to the DNNDev project (right click your solution | add | new item | web templates | web configuration)

 So you end up with this taxonomy:

…\DNNDev\DNNDev.sln
…\DNNDev\DNNDev.csproj
…\DNNDev\web.config
…\DNNDev\ web.debug.config
…\DNNDev\ web.release.config
…\DNNDev\ DesktopModiules\<module 1 name>.csproj (no web.config)
…\DNNDev\ DesktopModiules\<module 2 name>.csproj (no web.config)

I still have the VS designer problem of not recognizing the Telerik prefix tag because it seems the designer looks to the local project for its web.config and not the startup project.  The current work around is to add a @ Register tag to each acsx file that needs a Telerik control.  I would like to put a link in each VS project pointing to the web.config file in the virtual folder DNNDev  but I can’t seem to do that.  You have to add an actual file to each project which chokes IIS.

<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

 
New Post
1/6/2011 3:00 PM
 

Well, this explains why I had one module that worked and one that gave me grief.  The one that worked was set as the Startup Project for the solution and consequently its web.config was being picked up.  When I opened the 2nd module IIS picked up a 2nd web.config in its subfolder and barfed.  The solution was to make a common Startup project that mirrors the IIS web site and contains the one web.config.


Thanks for the help...ed
 
Previous
 
Next
HomeHomeOur CommunityOur CommunityGeneral Discuss...General Discuss...Web.config issueWeb.config issue


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out