hi i have the following problem after importing databse in c#.
i have import a mdf database in C#. but it has exception after pressing F5 for debugging.

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)

how can i solve this??

Recommended Answers

All 2 Replies

Hi
This is simple. First check whether you are able to connect Sql Server through SSMS or not.If you are able to connect through SSMS, then there may be a problem in connection string. If you are not able to connect through SSMS, then you had some problem with SQL Environment.

thnx i got it...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.