ASP.NET: Connecting to MSSQL Server using Windows Authentication/Credentials

How To | May 12th, 2010

I am learning ASP and ASP.NET for my new job, and today I was working on manipulating a Microsoft SQL database (SCUD) when I ran into a roadblock. I knew I had to use my own user credentials to connect to the secret through ASP.NET, something I thought would be a very simple matter. Well after fifteen minutes of attempting to work out why I couldn’t connect with my username and password (trying variations of the domain/myusername) I finally discovered the MSDN page I needed. Yes, it already exists there, but the fact that it took me so long to find what  I needed means it can’t hurt to refer to it and reinforce it’s presence on the web.

(more…)