Web.config Transformation And Deployment Options?

Nov 19, 2010

I am just starting my first MVC Web Application and have noticed that I now not only have a Web.config file in the root, but 2 sub-files, for Debug and Release configurations. I've read up a bit on what this is, in that I can put specific configurations for my different environments in each file, but I am confused as to when these seperate files are actually used.

Do I HAVE to use the built in Deployment/Publish tools within Visual Studio in order to benefit from this, or, if I set my build mode to Release, and do a simple build of my web application, then deploy the compiled files, along with the Web.config AND Web.Release.config, would that work?

I'm just not sure what deployment options I have to take advantage of these seperate config files?

View 1 Replies


Similar Messages:

Configuration :: Transformation With Config Files?

Aug 17, 2010

I am currently trying to publish a web application in TestRelease mode and when I do, the following dll is compiled and put into the bin folder.Microsoft.VisualStudio.Settings.dll.I do not get this dll when I comple in release or debug mode so wondered if there is a setting I can change so this dll does not appear in the bin folder when I compile in TestRelease or TestDebug mode ?When I get that dll in the bin folder and try to deploy the application to our test server, I receive the following message: Could not load file or assembly 'Microsoft.VisualStudio.Settings.dll' or one of its dependencies.Any suggestions on why that dll appears in the bin folder and how I can prevent it from being deployed when I pusblish through visual studio ?

View 1 Replies

Team Build 2010 And Web.config Transformation?

Nov 25, 2010

I'm struggling to get web.config transformations working with automated builds. We have a reasonably large solution, containing one ASP.NET web application and eight class libraries. We have three developers working on the project and, up to now, each has "published" the solution to a local folder then used file copy to deploy to a test server. I'm trying to put an automated build/deploy solution in place using TFS 2010. I created a build definition and added a call to msdeploy.exe in the build process template, to get the application deployed to the test server. So far, so good!

I then tried to implement web.config transforms and I just can't get them to work. If I build and publish locally on my PC, the "publish" folder has the correct, transformed web.config file. Using team build, the transformation just does not happen, and I just have the base web.config file. I tried adding a post-build step in the web application's project file, as others have suggested, similar to:

<target name="AfterBuild">
<TransformXml Source="Web.generic.config"
Transform="$(ProjectConfigTransformFileName)"
Destination="Web.Config" />
</target>

but this fails beacuse the source web.config file has an "applicationSettings" section. I get the error Could not find schema information for the element 'applicationSettings'.I've seen suggstions around adding arguments to the MSBuild task in the build definition like

/t:TransformWebConfig /p:Configuration=Debug

But this falls over when the class library projects are built, presumably because they don't have a web.config file.

View 3 Replies

Visual Studio :: Config Transformation Using XSLT?

May 10, 2010

The VS2010 Online Help for config transformation appears to be incorrect.If I add something like view plaincopy to clipboardprint?

View 5 Replies

Run Site Using Specific Web.config Transformation In Visual Studio

Nov 18, 2010

I'm using the web.config transformations on an ASP.NET site so I have .config settings for dev, test, and release environments. I need to run the source code in Visual Studio against the test database using the settings in Web.Test.config and I can't figure out how to do it. I tried changing the configuration to Test but it still uses the base Web.config settings.

View 1 Replies

Visual Studio 2010 - Apply The Web.config Transformation Before Creating The Installer?

Jun 7, 2010

I am working on an ASP.NET project in Visual Studio .NET 2010 and attempting to make an MSI installer using a Web Setup Project. I added the Primary output from the project (which seems to pull in the relevant dependencies) and the Content Files from the project (which pulls in the Web.config and the .svc files).

The issue is that rather than applying the XDT transform and creating the Web.config using the Web.Release.config, it just copies the Web.config, the Web.Release.config, and the Web.Debug.config into the installer without doing any transformation at all.

How do I get it to apply the Web.config transformation before creating the installer?

View 2 Replies

Configuration :: Web App Deployment Options

Jan 14, 2011

While developing my web application I was testing using the cassini web server and everything works great! So my program is complete and I am trying to publish it out to a client IIS server on a Windows 2008 R2 server. I have created an app.pool for this application and set it to run with a domain admin users (I am not using the "Administrator" account) since the file processing will be writing the file to a NAS device via a UNC path. When I start the debugging on the server and look at task manager it shows that the "w3wp.exe" is running using the domain admin account, but when I run my code it does not give me a run time error I just get the following warning in the event log.

View 11 Replies

Serialization Newbie Options In A Web Config

Jan 19, 2011

Code:
public class GroupInfo
{
private List<Structure> _sectors = new List<Structure>();
[XmlElement("Sector")]
public List<Structure> Sectors
{ get; set; }
[XmlElement("Person")]
public List<Users> Person
{ get; set; }
[code]...

View 10 Replies

Configuration :: How To Use Encrypt Web.config In Deployment

Mar 21, 2010

How to use encrypt web.config in deployment?Where it should be kept?

Or in other way how to encrypt web.config file in deployment?

View 5 Replies

Web Forms :: Warp Panel Refresh Options In Web Config

May 17, 2010

I have a WARP panel (warpNoteManager) that has a Drop down list (ddlNoteType), two WebImageButtons, (wibAdd) and (wibEdit) and a WebTextEdit (wteNoteManager).What I am doing is selecting the value from of wteNoteManager that I want to edit then click wibEdit so that the value from ddlNoteType can be loaded into wteNoteManager.

[Code]....

View 1 Replies

Configuration :: Change AccessConnectionString In Web.config After Deployment?

Apr 22, 2010

I'm developping an ASP.NET web applition which will be running on a intranet server. The web application will read and write data from / to an access mdb.

The link to this mdb is specified under the web.config file. However, in this web.config, the connection string points to a absolute path (for ex. c:information.mdb).

Is it possble to change this path after the web application is installed on the server (without having it to open in visual studio)? This is needed, because the application will be installed at other locations too, all pointing towards their own server and mdb (and this mdb file won't be always be on the c: drive).

I tried opening the web.config file with notepad, and changing it. Everything seems to work, but I'm not sure this method is good. Since I assumed you have to rebuild the application if you change somthing in the code...

View 2 Replies

Visual Studio :: 2010 1 Click Deploy, Config Transform Options Not Visible?

Feb 18, 2011

I have installed VS2010 ultimate and have read with interest about the new publish options, config transformations but none of them are available. I have tried creating different release versions and cannot see the option, also have no new options for publish, just look like the VS2008 ones.

Is there some service pack or pack that i need to install these or does it sound like a reinstall?

View 1 Replies

Web Forms :: Treeview / SiteMapDataSource - Get Tree Layout That Matches The Numbers Of Options But No Text On Any Of Options To Click

Jan 18, 2011

I have a Default.aspx program that contains a Treeview with a SiteMapDataSource. I also have a web.sitemap loaded up with urls. When I run the deafult app I get the tree layout that matches the numbers of options but no text on any of the options to click.

View 1 Replies

Configuration :: Can Create An Incremental Deployment Package Using Either Visual Studio 2010 Web Deployment Projects

Mar 27, 2011

Can I create an incremental deployment package using either Visual Studio 2010 Web Deployment Projects or Web Deploy (Web Deployment Tool) .

I need to automatically select changed files from a source and destination or a change set on TFS and build a deployment package only with the changed files.

View 9 Replies

C# - .net 4 Xslt Transformation Extension Function Broken?

Aug 4, 2010

I'm in the process of upgrading an asp.net v3.5 web app. to v4 and I'm facing some problems with XSLT transformations I use on XmlDataSource objects.

Part of a XSLT file:

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:HttpUtility="ds:HttpUtility">
<xsl:output method="xml" indent="yes" encoding="utf-8"/>
<xsl:template match="/Menus">

[Code]....


The problem seems to be in the line

<xsl:value-of select="HttpUtility:HtmlEncode(MenuTitle)"/>

Removing this and replacing it with a normal text, it will work. The way I setup the XML datasource:

xmlDataSource.TransformArgumentList.AddExtensionObject("ds:HttpUtility", new System.Web.HttpUtility());
xmlDataSource.Data = Cache.FetchPageMenu();

I've been searching the Microsoft pages for any changes in v4, but can't find any. All this worked fine in v3.5 (and before v2). Not receiving any errors, the data is just not displaying.

View 1 Replies

SQL Server :: Derived Column Transformation / Add Extra Logic To Derived Column Expression?

Dec 22, 2010

I'm trying to figure out how add extra logic to this derived column expression:

LEN(TRIM(pup_date)) == 0 ? NULL(DT_DATE) : ((DT_DATE)(SUBSTRING(pup_date,5,2) + "-" + SUBSTRING(pup_date,7,2) + "-" + SUBSTRING(pup_date,1,4)))

If there's a 0 in the field the code inserts a null. Otherwise it inserts a date. How can I change this to insert a NULL if a question mark "?" appears in the column?

This is what I tied using the OR operator but it's not working:

LEN(TRIM(pup_date)) == 0 || LEN(TRIM(pup_date)) == "?" ? NULL(DT_DATE) : ((DT_DATE)(SUBSTRING(pup_date,5,2) + "-" + SUBSTRING(pup_date,7,2) + "-" + SUBSTRING(pup_date,1,4)))

View 2 Replies

Visual Studio :: Errors In Root Machine.config And Web.config After 2010 Installation

Jan 19, 2011

I just installed VS2010 and opened the root machine.config and web.config files for review and I found some errors. In machine.config, the following line has errors in both entries for <Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior>. When I hover the cursor over them I get a tooltip text which displays: "The element 'endpointBehaviors' has invalid child element 'Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior'. List of possible elements expected: '...(list of options here)...'. The same problem happens for the second appereance in tag <serviceBehaviors>.

[Code]....

In web.config, there is a tag called <protocols> that has an error with a tooltip text that says "The element 'system.web' has invalid child element 'protocols'. List of possible elements expected: '...(list of options here)...'.

View 2 Replies

How To Create A Common Web.config File And A Bunch Of Specific Web.config Files

Feb 16, 2011

Currently, I work on an ASP.NET project which is hosted under version control and is used on several developer machines, tester machine and production environment.

In three cases, configuration (Web.config) may be different. For example, developer and tester environments use testing SQL Server, whereas in production environment, another SQL Server is accessed, so the connection string is different in those cases.

We want to keep three versions of Web.config in subversion. But modifying each of three files every time we need to add, remove or change a common setting is annoying: it would be nice to have a common, master Web.config, which will be inherited by each of the three Web.config files.

How to set up an ASP.NET project which will use a master configuration file and different slave configuration files on different machines, thus sharing the same project/source code/configuration files in subversion?

View 2 Replies

How To Determine Which Parent Config File Is Locking A Web.config Setting

Mar 15, 2011

When I open my ASP.NET site in IIS and try to open the .NET Trust Levels, I get an error message:

.NET Trust Levels There was an error while performing this operation.

Details:
Filename: ?C:inetpubwwwrootmyappweb.config
Line number: 445

Error: This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"),or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false".

I've checked a few places, but I haven't found anything that seems like it would be locking that setting. Is there a systematic way of determining where that setting is locked?

I'm using IIS 7.5 and .NET 3.5 sp1.

View 1 Replies

Unable To Read Config Settings From External Config Files

Sep 1, 2010

We are experiencing some strange behaviour on one of our ASP.NET web servers (Windows 2003 64-bit). After some activity, two third-party controls are unable to run correctly. One is log4net (it does not write error messages out) and the other is a menu control (it displays eval message instead of picking up its license). The one common thread is that both controls pick up their config from external config files (linked to from web.config).

Just wondering if anyone has any thoughts on this or experienced this in any way. Is it related to file/folder rights? The server has been running fine for a while and just started exhibiting this behaviour. Perhaps it occurs around the time the worker processes are recycled.

View 1 Replies

Child Web.config Can't Clear <pages><controls> From Parent Web.config

Apr 13, 2010

How can I "clear" the vendor defined <controls> in my child app's web.config?

Parent Web Config.

[code]....

I have it working for the <tagMapping> section, but <controls> does not support <clear/>.

View 2 Replies

C# - Command Or Setting For A Child Web.config To Ignore The Parent Web.config

Jun 23, 2010

I am running into a problem with a web.config in a child project that has the same connection string setting as a parent. We have this in several of our web apps but there is one case where we want a child not to use the parent web.config. Is there a setting or command in the child web.config to ignore the parent web.config?

View 4 Replies

Configuration :: Deploy Web.config And App.config Connection String?

May 3, 2010

I have deploy my web site, it contains a project!

in MyWeb there are all the aspx page and some entites datamodel, in MyApp there are the class with function like "getter data from DB" and there is a entity data model.

afeter the deploy, I have only the web.config and the connection string for the entity datamodel....itīs run ok, read/write the data on the DB.

The problem is with MyApp.....after the deploy it is a dll file and I donīt have the app.config and the entity inside it donīt run, not read/write nothing on the DB.

There arenīt error or messager but not read/write the data in the MyApp project.

all run on the iis 7

now...the question is:

I lose the connection string (in app.config) after the deploy?

Can I put a entity in the MyWeb and read it in another project (myApp)?

ps: for connect to DB I use not the c# code:

var db=from x in AccessDB.Example select x;

View 1 Replies

Machine.config / Web.config In .NET Framework 3.0 / 3.5 And Framewor 1.1 / 1.0 Cascade?

Aug 9, 2010

I made a change in my machine.config for a 1.1 application and then later I upgraded the application to .Net Framework 3.0/3.5. Will that configuration change still apply or do I have to make that change in my local web.config for the 2.0 machine.config/web.config?

View 1 Replies

Read Settings / Sections From The Web.config Or App.config File?

Jul 8, 2010

I have many Connection strings in my web.config file. I also have a "dataConfiguration" setting in the same file which specifies what database my app connects to.

How do I read the "defaultDatabase" setting / section from the, see below xml file.
<configuration>

<configSections> [code]....

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved