I have a DB that I can access in MS SQL Server Management Studio and from an application that I used to create the DB using code first. I am trying to connect to that DB via a different app and my connection fails every time. In Visual Studio > SQL Server Object Explorer it lists the SQL Server as "(localdb)\MSSQLLocalDB". When I try to use a single "\" in my connection string VS prompts me saying unrecognized escape sequence and won't build. When I use "\\" I can't connect. What am I missing?
string connStr = "Data Source=(localdb)\\MSSQLLocalDB;Initial Catalog=myDatabaseName;Integrated Security=True";
SqlConnection con = new SqlConnection(connStr);