Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Override access to conn string in web.config
Message
De
08/08/2007 10:23:21
Timothy Bryan
Sharpline Consultants
Conroe, Texas, États-Unis
 
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
01245016
Message ID:
01246777
Vues:
14
Hi Kevin,

>
>>Since with ASP.net there is a App_Data directory designed in, are you planning any way to use data in this directory within the web.config file? It appears one needs to use Server.MapPath() to find it in the connection string, and I don't know how to do this in an xml file.
>
>You can use the "|DataDirectory|" stringn in the web.config file to specify your database is located in the App_Data directory. Here is more information on how to use this.
>
>http://msdn2.microsoft.com/en-us/library/hktw939c.aspx
>

Someone had suggested using this awhile back but I could not confirm it worked. I finally got my host to move me to another server as they could not get my app to work on it. Once they moved me it worked as well did the |DataDirectory| in the connection string.
Thanks a bunch
Tim
Timothy Bryan
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform