i am trying to connect sql server 2005 express using c#.net 3.5.
my connection string is
"Server=.\SQLExpress;AttachDbFilename=C:\Program Files\Microsoft SQL Server\MSSQL.2\MSSQL\DATA\db_naren.mdf;Database=db_naren; Trusted_Connection=Yes;"
this is working fine when i am connecting to sql server from the local machine.
When i am trying to connect from someother machine to server it is giving error like
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: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
i added previliges in add new administrator on SQL Server 2005 Surface Area Configuration . and i made changes on
SQL Server 2005 Surface Area Configuration page, on
Database Engine --> Remote Connections -->Local and remote connections -->
Using both TCP/IP and named pipelines.
still same error i am getting from client machine i am using connection string as
"Server=MyServer\SQLExpress;AttachDbFilename=C:\Program Files\Microsoft SQL Server\MSSQL.2\MSSQL\DATA\db_naren.mdf;Database=db_nare; Trusted_Connection=Yes;"
is there any thing i need to do to connect from client machine to server?please
View Complete Post