By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,948 Members | 1,056 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,948 IT Pros & Developers. It's quick & easy.

VS VB Express 2010 Cannot Connect to SQL Express Database

P: 124
I am confused by database connections in the VS 2010 VB Express version I installed recently. I want it to connect to an existing database in an instance of SQL Server Express (2008R2) I have installed on the same computer but each time I try, it keeps prompting me for a "SQL Server Database File" rather than connecting to the server and letting me choose a database. I thought "SQL Server Database File" means an MDF file, but when I try to browse to an MDF, I get "Access denied." How does one establish a connection to an existing SQL Express instance and connect to a particular database? Thank you in advance for any advice.
Apr 5 '13 #1
Share this Question
Share on Google+
4 Replies

P: 46
Have you tried to connect through Server Explorer? Hit Control/Alt "S", then "Add Connection" and a dialog pops up that will guide you through the steps.
Apr 9 '13 #2

Expert 100+
P: 1,295
¿Can you share your connection method and your connection string?, perhaps you're looking for a file instead of connecting to a server.
Apr 10 '13 #3

P: 124
Unfortunately, VS 2010 VB Express only gives me one option to connect to SQL Server and that is via a "SQL Server File." When I browse to an MDF file, I get "Access Denied." There is no option for SQL Server or SQL Server Client in the dropdown list, just Access and SQL Server file. I must have downloaded the stripped down version of VS2010 VB Express...
Apr 11 '13 #4

Expert Mod 15k+
P: 31,662
This seems like a Visual Studio question rather than a SQL Server one. I'll move it for you to see if that produces any further help.
Apr 13 '13 #5

Post your reply

Sign in to post your reply or Sign up for a free account.