Loading ...

Start SSMS with a instance connected and logged in with a user at Windows Start | CodeAsp.Net

Start SSMS with a instance connected and logged in with a user at Windows Start

 /5
0 (0votes)

Whenever I start my Windows. I open SSMS, select server, select user and database to connect to database. This process I have to do every time when Windows is restarted. I decided to make Windows do the same work for me when it is restarted. Below are the steps which will help you to do the same:

  1. Copy the SSMS shortcut.

  2. Select the "StartUp" folder from "AllPrograms"

  3. Right click it and select "Open all users" option.

  4. Paste the SSMS shortcut you copied in first step into this (Startup) folder. Right click the shortcut and select "Properties".




  5. In the "Shortcut" tab you will see the "Target" textbox with this kind of value:

    "D:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Ssms.exe"

    Windows Drive may be different for you. I added the following value " -S localhost -d mydb -U sa -P test -nosplash" (without quotes) in that textbox so that the full value of the textbox looks like: 

    "D:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Ssms.exe" -S localhost -d mydb -U sa -P test  -nosplash

    Above, "localhost" is the Instance name, mydb is the Database name, sa is the username and test is the password.

After doing all the steps my SSMS is started itself on Windows start with logged in user and with selected database. 

Comments (no comments yet)

Top Posts