The API only allows you to write from it.
In VStudio, you have to create a file called app.config (not
myapp.exe.confi g) in your project's base directory and you have to include
it into your projet (it will be included by default if you create it with
VStudio but not if you create it outside of Studio).
Then, when you compile your project, Studio will copy it to bin/Debug or
bin/Release depending on the config, and it will rename it MyApp.exe.confi g.
Also, don't try to create MyApp.exe.confi g directly into bin\Debug, it will
get overwritten every time you compile.
Bruno.
"Simon Harvey" <sh856531@micro softs_free_emai l_service.com> a écrit dans le
message de news:ua******** ******@tk2msftn gp13.phx.gbl...
Hi chaps,
Can someone direct me to the necessary class that will allow me to write
information into my applications .config file? I know how to read
information but I'm sure there must be a way to write out to the config
file easily as well.
Also, my application doesnt actually have a config file created by
default. I thought the VS template would create one automatically but it doesnt. Is
it ok just to make one in the form:
MyApp.exe.confi g
Will that work?
Thanbks everyone
Simon