473,806 Members | 2,795 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I prevent Publish Web Site from overwriting web.config?

Publish Web Site in VS.NET 2005 helps but I don't want it to copy web.config
to from development to staging.

It doesn't seem be a way around it, or maybe I'm missing something?
Apr 5 '07 #1
3 1806
I don't think there is an easy way around this. However, if you have settings
that you don't want to have to re-enter, you can use the appSettings section
that allows you to specify an external file from which the appSettings
section is loaded. The appSettings element attribute is 'file=...'
Peter

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net


"Stan B" wrote:
Publish Web Site in VS.NET 2005 helps but I don't want it to copy web.config
to from development to staging.

It doesn't seem be a way around it, or maybe I'm missing something?
Apr 5 '07 #2
"Stan B" <st**@community .nospam.comwrot e in message
news:4b******** *************** @msnews.microso ft.com...
It doesn't seem be a way around it, or maybe I'm missing something?
Thankfully, Microsoft have provided a solution for this:
http://www.google.co.uk/search?sourc...oyment+Project
Apr 5 '07 #3
I found a workaround:

1. Publish web site to the local IIS
2. Add compiled web site from local ISS to VS.NET solution
3. Using Copy Web tool select all files in the source site except web.config
Apr 6 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
3169
by: Graham | last post by:
I noticed a similar post awhile ago and in terms of my problem it wasnt a suitable answer so I will ask again. I have VS2005 running a on development machine in my office where I do all my development on existing and new applications. This environment also has its own Sql Server with dev versions of all our live Databases. Our live production server also its own Sql Server, these 2 Sql Servers are kept completely separate (for obvious...
6
3836
by: ewolfman | last post by:
Hi, I've read many posts in several news groups, but can't figure out how to publish my website. The specific error I'm getting (on the "successfully published website") is "Could not load the assembly 'App_Web_vxfyglsm'. Make sure that it is compiled before accessing the page". I checked - The assembly DOES exist in the target web folder.
1
1392
by: VB Programmer | last post by:
My ASP.NET 2.0 site takes about 10 min to publish to my webserver. There's only 3 ASPX pages, VERY MINIMAL code (< 100 lines) and I'm not using any membership stuff etc... (even though the ASPNETDB.MDF is over 10MB) Any ideas how I can speed up the process, or better yet, JUST copy over certain files (ie the things that have changed?) Thanks!
1
1277
by: Bill Long | last post by:
I have a .NET 1.1 application (C#) that I converted to .NET 2.0... Conversion was pretty painless, code runs from the development environment no problem... but when I try and publish... It says everything was successful. So what's the problem??? It never creates any files in the output directory... It will delete any existing ones but never creates anything. Nothing ever gets published Any ideas would be appreciated --
9
2383
by: Alex Greenberg | last post by:
I don't know, but I find the Publish Web Site feature very lacking and weak. I mean, why does the damn thing have to delete unrelated directories like /images /documents etc. This is so impractical, what if my users generate these documents or images through their interaction with the site, and then I change some code and publish it, boom, everything is gone. I cannot put these folders outside the solution due to security/pathing...
2
2101
by: Todd | last post by:
My web site compiles fine. Tihs was a VS 2003 working application that was converted to VS 2005. When I try to publish to a directory I get a "Data at the root level is invalid." error in the published version of web.config line 1. The contents does not reflect the real web.config. I am able to publish other web sites. Published version with error looks like: vti_encoding:SR|utf8-nl vti_timelastmodified:TR|08 Aug 2004 19:02:17...
6
4362
by: Eric | last post by:
I have what is hopefully a quick question. I want to have a quick and easy method for deploying my website to our test environment. I need something to do nearly the same thing as the "Publish Web Site" option under the build menu, except I don't want it to copy over the web.config file. There are a few settings that need to be different, so I want the publish process to leave the web.config file alone. What is the easiest way to do...
3
1701
by: PokerMan | last post by:
HI When i publish my site, it overwrites all files. but when i have some large files included such as mp3s. It overwrites these and even tho i havent touched them it reuploads all of them. Anyway i can set it to not do this for specific files? Thanks
3
2925
by: Joseph Geretz | last post by:
Visual Studio 2005: I'm using Publish to 'mirror' my development site onto the staging site. It's working beautifully except for one annoyance; it keeps overwriting web.config on the staging box with the web.config from my development box. There's got to be a way to address this. By its nature, the config file is likely to be different on different platforms and so what I'd like is to be able to exclude the config file from the publish...
0
9599
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
10374
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9193
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7650
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6877
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5684
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4330
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3853
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3010
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.