Configuring webconfig

G

Guest

I don't want to use the default db "ASPNETDB.MDF" that is placed in the
"App_Data " folder. I have created "myDB.MDF" and have run
"aspnet_regsql.exe" tool successfully. I now want to encompass it into
"myWebSite". However, I am unsure what my webconfig should look like. I've
read an article and it gave me the following code.

<configuration>
<connectionStrings>
<add name="MyDB" connectionString="..." />
</connectionStrings>
<system.web>
... authentication & authorization settings ...

<membership defaultProvider="CustomizedProvider">
<providers>
<add name="CustomizedProvider"
type="System.Web.Security.SqlMembershipProvider"
connectionStringName="MyDB"
applicationName="ScottsProject"
minRequiredPasswordLength="5"
minRequiredNonalphanumericCharacters="0" />
</providers>
</membership>
</system.web>
</configuration>

My question is what should be substituted in place of "..." in the statement
connectionString="..." ? My DB location is "C:\myDBFolder". Also I tried to
use ASP.NET configuration utility but it placed "ASPNETDB.MDF" in my
"App_Data" folder. Instead I would want "myDB.MDF" be placed there. Is this
possible?
 

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

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top