Connection String Help

From: JJ (JJ_at_discussions.microsoft.com)
Date: 02/10/05


Date: Thu, 10 Feb 2005 12:57:02 -0800

Hello,
I was wondering what the best way would be to dynamically determine and
store connection string information. What I mean by this is that I want the
application to user the servervariable to determine what location it is
running in and then dynamically assign a connection string value based on
that location. I was planning on doing this from the codebehind pages which
works fine because I am able to use the response object to determin where the
code is running but I am not sure what to do in a vb class file where I have
no access to server variables. Any Ideas???

THANKS



Relevant Pages

  • Connection String
    ... store connection string information. ... running in and then dynamically assign a connection string value based on ... no access to server variables. ...
    (microsoft.public.dotnet.general)
  • Re: Connection String Help
    ... namespace and also reference the System.Web assembly if ... The drawback is you won't be able to use the code outside of a web ... >running in and then dynamically assign a connection string value based on ... >no access to server variables. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Changing SQL connection at runtime
    ... Store connection string data in a default table. ... they want to use froma drop down box, then connect to that server. ... I've been searching for ages to find a way to do this, ...
    (microsoft.public.dotnet.general)
  • Re: Connection String Help
    ... > store connection string information. ... > running in and then dynamically assign a connection string value based on ... > works fine because I am able to use the response object to determin where ... Why don't you have access to the server object through current context? ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Looking for ASP.NET/SQL Server 2000 App Security Recommendations
    ... connection string information be stored for and accessed by the ... One possibility is to store the connection string in an encrypted format within the web.config file like this... ... In the connection string, set the Persist Security Info named value to false, so it will hide security sensitive info, like password from being exposed in connection string property of the SqlConnection object. ...
    (microsoft.public.dotnet.framework.aspnet.security)