<add name="LatTejDB" connectionstring="Data Source=RAJ;Initial Catalog=NewMilkSupply;Integrated Security=True" providername="System.Data.SqlClient" />
From the
ConnectionString
, it is clear that you are trying to connect to some Server
RAJ
.
For that, you need to
Enable TCP/IP and Named Pipes
in
SQL Server Configuration Manager.
Refer -
Enable Named Pipes and TCP/IP Connections[
^] to know how to
Enable
it.
I am just taking the steps from there and listing them below.
- Select Start, and in your list of programs, select SQL Server Configuration Manager.
- Navigate to SQL Server Configuration Manager > SQL Server Network Configuration > Protocols for <machine instance>.
- Double-click Named Pipes. The Named Pipes Properties screen appears.
- From Enabled, select
Yes
. Then click OK
. - Double-click TCP/IP. The TCP/IP Properties screen appears.
- On the Protocol tab, ensure
Yes
is selected for Enabled
. On the IP
Addresses tab, ensure that Yes
is selected for the appropriate IP
Address. Also, ensure that the appropriate TCP
Port is indicated. - Click OK.
- From SQL Server Management Studio, restart the server instance.