Click here to Skip to main content
15,887,485 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
VB
Using conn As New SqlConnection("Data Source=.\SQLEXPRESS;AttachDbFilename=..\App_Data\Astronomy.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True")


This works in VB.net with a "C:\path" in place of "..".

Not sure how to access SQL functioning on my webserver.

This is how to do it from VB.net in SQL Express ".\SQLEXPRESS"

How is it done from the web server?
Posted
Comments
[no name] 18-Mar-13 22:30pm    
www.connectionstrings.com should answer whatever it is that you are really asking. Not sure what you mean by "How is it done from the web server"
Chinmaya C 19-Mar-13 1:06am    
instead of

AttachDbFilename=..\App_Data\Astronomy.mdf;

try with

AttachDbFilename=App_Data\Astronomy.mdf;

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900