473,791 Members | 2,853 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

config file dosn't work when I deploy my app

I have a config file in my app ,,called app.config.it works fine in debug
but when I deploy application it has no effect.Any suggestion??
Thanks for your help.

Here is my app.config
?xml version="1.0" encoding="utf-8" ?>
<configuratio n>
<appSettings>
<add key="defaultRep ortServer" value="myserver 01" />
<add key="defaultDoc Library" value="http://test/mytest" />
</appSettings>
</configuration>

Nov 16 '05 #1
2 1746
app.config is a Visual Studio thing. VS.NET copies this file into the build directory (bin\debug for example) as <yourapp>.exe.c onfig

The config file needs to have the same name as your .exe with ".config" on the end of it for the runtime to pick it up. So if your application is called winword.exe you need to call your config file winword.exe.con fig

Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

I have a config file in my app ,,called app.config.it works fine in debug
but when I deploy application it has no effect.Any suggestion??
Thanks for your help.

Here is my app.config
?xml version="1.0" encoding="utf-8" ?>
<configuratio n>
<appSettings>
<add key="defaultRep ortServer" value="myserver 01" />
<add key="defaultDoc Library" value="http://test/mytest" />
</appSettings>
</configuration>

Nov 16 '05 #2
Thanks very much.it is now workin.
ALi
"Richard Blewett [DevelopMentor]" <ri******@NOSPA Mdevelop.com> wrote in
message news:OX******** ******@TK2MSFTN GP14.phx.gbl...
app.config is a Visual Studio thing. VS.NET copies this file into the build directory (bin\debug for example) as <yourapp>.exe.c onfig
The config file needs to have the same name as your .exe with ".config" on the end of it for the runtime to pick it up. So if your application is
called winword.exe you need to call your config file winword.exe.con fig
Richard Blewett - DevelopMentor
http://www.dotnetconsult.co.uk/weblog
http://www.dotnetconsult.co.uk

I have a config file in my app ,,called app.config.it works fine in debug but when I deploy application it has no effect.Any suggestion??
Thanks for your help.

Here is my app.config
?xml version="1.0" encoding="utf-8" ?>
<configuratio n>
<appSettings>
<add key="defaultRep ortServer" value="myserver 01" />
<add key="defaultDoc Library" value="http://test/mytest" />
</appSettings>
</configuration>

Nov 16 '05 #3

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

Similar topics

9
8278
by: ALI-R | last post by:
Hi,, I have two questions : 1) Is it mandatory that config file of a desktop application must be App.config 2) Is it possible to update config file in your code?? thanks for your help. ALI
8
2001
by: Robert | last post by:
I have what I think should be a pretty common scenario in a corporate environment. I have a web app and three environments on three servers: Development, QA and Production. We develop in development and then deploy the updated application to our QA server and then once tested to our production server. The application has a web.config file. The contents of the file (appsettings part) are different in all three environments because...
8
3722
by: Henry | last post by:
Hi, in a Windows form VB.Net project I use localization for all texts. In App.Config I added: <appSettings> <add key="locale" value="de"/> </appSettings> In the project I have ressource files strings.resx (English text) and strings.de.resx for the German texts.
12
13439
by: dbuchanan | last post by:
Hello, (Is this the proper newsgroup?) === Background === I am building a solution with two projects. One project is my data access layer which contains my DataSet as an xsd file. The XSD file was built by draging tables from the Data Sources pane. Auto-generated code created the files associated wtih the XSD file (xss,
0
9669
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10207
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10154
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
9029
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
7537
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
6776
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();...
1
4109
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
3713
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2913
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.