my config is deleted

G

Guest

vb vs2003
in my bin folder I have a config file for my app "myConfig.exe" as
"myConfig.exe.config"
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<appSettings>
<add key="v3" value="Value 3" />
</appSettings>
</configuration>
If I execute the exe from the bin... the app finds my config file. If I run
it using debuger the config file is deleted and my app reports the config is
not found.
any reasons why my config is deleted ?
thanks for your help
 
C

Claes Bergefall

Not sure why it's deleted, but you should make use of the built in support
for config files instead. Move the file so it is where the rest of you
source code is, rename it to app.config. and add it to your project. The
compiler will automatically copy it to your bin directory with the correct
name (myConfig.exe.config).

/claes
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top