Something really weird, I have an sql server alias configured (using 2008) since my instance name is different from co-workers, everything works well until I disconnect from LAN/Internet

Named Pipes is enabled and TCP/IP too in SQL Server Configuration Manager, I also disabled firewall but still not working.

This is my Alias configuration for both 32 and 64 bits.

```
Alias Name: .\Dev
Protocol: Named Pipes.
PipeName: \\localhost\pipe\sql\query
server: localhost

```

this is the error that i receive in asp.net

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)

Update.

My intent is not to change my connection string to avoid constantly merges in web.config

this is my connection string

```
Data Source=.\Dev;Initial Catalog=MyDatabase;Persist Security Info=True;User ID=x;Password=x.;Pooling=False;"
         providerName="System.Data.SqlClient

```

update

I discover that after restarting my system everything works ok, i connect to a WLAN and later disconnect problems appears again, seems that something goes bad after disconnecting from WLAN, alias stops working.