Google Groups Home
Help | Sign in
ConectionString in app.config ignored
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
cppquester  
View profile
 More options May 13, 11:07 am
From: cppquester <cppques...@googlemail.com>
Date: Tue, 13 May 2008 08:07:28 -0700 (PDT)
Local: Tues, May 13 2008 11:07 am
Subject: ConectionString in app.config ignored
If I change my app.config file, nothing happens: The DB is accessed
like before.
No error, everything seems to work normal.
I rebuild my solution, even after restarting VS2005.

My questions:
1. When is the input of app.config taken? Why am I not seeing any
effect?

2. app.config appears in one project of my solution, I cannot  se it
in the release version.
The data isn't in  MyMain.exe.config
Where is the data stored?

Thanks,
regards,
Marc


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Cerebrus  
View profile
 More options May 13, 1:10 pm
From: Cerebrus <zorg...@sify.com>
Date: Tue, 13 May 2008 10:10:57 -0700 (PDT)
Local: Tues, May 13 2008 1:10 pm
Subject: Re: ConectionString in app.config ignored
Your config will be built into the the Bin directory of the current
project only. I'm currently dealing with the same problem and am
having to manually copy the "MyProject.dll.config" file to the Startup
project's Bin directory.

I wonder if someone else can shed light on a way to automatically
build the config file to the main project build directory.

On May 13, 8:07 pm, cppquester <cppques...@googlemail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Andrew Badera  
View profile
 More options May 13, 1:16 pm
From: "Andrew Badera" <and...@badera.us>
Date: Tue, 13 May 2008 13:16:23 -0400
Local: Tues, May 13 2008 1:16 pm
Subject: Re: [DotNetDevelopment] Re: ConectionString in app.config ignored

I'm having a hard time understanding the issue ... why do you have to fuddle
around with the .config C? Educate me please!

OP:
.config files are read on startup/application pool recycle (I think)/web app
recompile

.config file sections can be manually refreshed using .RefreshSection()

--
--
--Andy Badera
http://higherefficiency.net
http://flipbitsnotburgers.blogspot.com/
http://andrew.badera.us/
http://changeroundup.com/
and...@badera.us
(518) 641-1280
Google me: http://www.google.com/search?q=andrew+badera

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Crisatunity (blog.crisatunity.com)  
View profile
 More options May 13, 2:52 pm
From: "Crisatunity (blog.crisatunity.com)" <mich...@crisatunity.com>
Date: Tue, 13 May 2008 11:52:41 -0700 (PDT)
Local: Tues, May 13 2008 2:52 pm
Subject: Re: ConectionString in app.config ignored

> I wonder if someone else can shed light on a way to automatically
> build the config file to the main project build directory.

Cerebrus - get away from your libraries having an "application" config
file.  They are for, you guessed it, applications.  If your library is
utterly dependent upon config information and you don't even have an
application then you've got to get into some fancy deployment
operations - like getting your config information into the host's
framework config.

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
cppquester  
View profile
 More options May 14, 3:32 am
From: cppquester <cppques...@googlemail.com>
Date: Wed, 14 May 2008 00:32:17 -0700 (PDT)
Local: Wed, May 14 2008 3:32 am
Subject: Re: ConectionString in app.config ignored
On May 13, 7:16 pm, "Andrew Badera" <and...@badera.us> wrote:

> I'm having a hard time understanding the issue ... why do you have to fuddle
> around with the .config C? Educate me please!

> OP:
> .config files are read on startup/application pool recycle (I think)/web app
> recompile

I want to be able to change the DB connect string (DSN, name,
password). I think this information is in the
config file (of one project of my solution, actually I don't see the
information in the exe.config file of the program)
But there isn't any effect when I change it in the config file and
rebuild afterwards.
The program still uses the same DB.

Regards,
Marc


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Andrew Badera  
View profile
 More options May 14, 2:33 pm
From: "Andrew Badera" <and...@badera.us>
Date: Wed, 14 May 2008 14:33:41 -0400
Local: Wed, May 14 2008 2:33 pm
Subject: Re: [DotNetDevelopment] Re: ConectionString in app.config ignored

You realize that only a single config file is deployed for an entire
application or website, right? And that's the app.config of your target
project, or web.config of the website you're building. Are you trying to use
multiple .config files for a single solution?

On Wed, May 14, 2008 at 3:32 AM, cppquester <cppques...@googlemail.com>
wrote:

--
--
--Andy Badera
http://higherefficiency.net
http://flipbitsnotburgers.blogspot.com/
http://andrew.badera.us/
http://changeroundup.com/
and...@badera.us
(518) 641-1280
Google me: http://www.google.com/search?q=andrew+badera

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google