Before trying to connect to your database instance, please enable network protocols. The following link will tell you how:
Enable Named Pipes and TCP/IP.
After that, restart your SQL Server instance.
1.On the Start menu, point to All Programs, point to Microsoft SQL Server 2005, point to Configuration Tools, and then click SQL Server Configuration Manager.
2.In SQL Server Configuration Manager, expand Services, and then click SQL Server.
3.In the results pane, right-click SQL Server (MSSQLSERVER), and then click Restart. Stopping and restarting the service will have the same effect. If SQL Server Agent is running, you will receive a notice that SQL Server Agent will also stop. In that case, choose “Yes”.
Now you can use SQL Server Management Studio to connect to your database instance, and change the “Auto close” option on your Sharepoint databases.
Hope this helps.