Click here to Skip to main content
15,917,731 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

When I try to install Sql server 2008 r2 on my windows 7 32 bit ultimate I get this error.[^]

I click continue. and after installing when I want to connect it from visual studio I get this error:

SQLException was unhandled A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL server is configured to allow remote connections.(provider:Named Pipes Provider,error:40-could not open a connection to SQL Server)

In installation wizard I saw that the instance name is not applicable.

How I can solve these problems and connect to sql server 2008 r2 from vs2010?

This is a screen shot from my sql configuration:[^]
Updated 1-Nov-12 8:24am
skydger 1-Nov-12 14:55pm    
Can you establish connection via SQL Server Management Studio to your server?
suraty 1-Nov-12 15:06pm    
I create a database in sql server management. I can not connect it from visual studio 2010.
skydger 1-Nov-12 15:12pm    
Check the protocols in SQL Server Configuration Manager (Configuration Tools folder in Program menu). Which ones are enabled?
suraty 1-Nov-12 15:20pm    
shared memory and tcp/Ip are enabled. and Named pipes and VIA are disabled.
suraty 1-Nov-12 15:30pm    
Please see this screen shot:
Instance name is not applicable. Is this the reason of cause error?
Why instance name is not applicable?

This helped me, I was suffering from the same trouble just a few days ago:
Share this answer
Share this answer

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