 |
BOOK: Beginning ASP.NET 4.5 : in C# and VB
 | This is the forum to discuss the Wrox book Beginning ASP.NET 4.5: in C# and VB by Imar Spaanjaars; ISBN: 978-1-118-31180-6 |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: Beginning ASP.NET 4.5 : in C# and VB section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|
|

March 29th, 2015, 07:02 AM
|
|
Authorized User
|
|
Join Date: Jan 2015
Posts: 16
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
Cannot open SSMS and Visual Studio at the same time!
Hello,
I am encountering a weird problem since I started working. I cannot open SSMS and VS simultaneously! Why?
I have VS 2010 and SSMS 2012
Beside that, every time I open VS and open the site solution, I need to restart my SQL server (Through the Sql manager), is this normal?
And is it normal to have 2 sql servers:
- MSSQL and SQLEXPRESS
Can I get rid of one? 
Thanks
|
|

April 4th, 2015, 04:06 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi there,
Can you define "cannot open SSMS and VS simultaneously!"? What happens when you do so? Does it crash? Do you get an error?
>> Beside that, every time I open VS and open the site solution, I need to restart my SQL server (Through the Sql manager), is this normal?
Not at all. Why do you have to do this?
>> And is it normal to have 2 sql servers
I have 4 versions on my machine ;-) So, it's not abnormal. MSSQLseems to be a full version, and the other is SQL Express. They can live side by side without issues.
Cheers,
Imar
|
|

April 4th, 2015, 04:14 AM
|
|
Authorized User
|
|
Join Date: Jan 2015
Posts: 16
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
Hello,
When I open my solution in VS. and then try to open the same database in SSMS it says:
cannot open instance is used by another application
|
|

April 4th, 2015, 04:27 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Can you specify the exact error message?
If I understand you correctly this may be by design. SQL Server locks parts of the database when you're editing it. Try closing the connection on the Database Explorer or Server Explorer. Then you should be able to have them open side by side.;
Cheers,
Imar
|
|

April 4th, 2015, 10:10 AM
|
|
Authorized User
|
|
Join Date: Jan 2015
Posts: 16
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
I tried the following:
I opened SSMS, opened the database successfully. Then I opened VS, the databases connections on the server explorer had all the red X, and when I try to open the database from server explorer in VS it gives me the following:
Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed.
BUT when I restarted the servers from the SQL configuration manager, it opened in VS :)
UNFORTUNATELY, in SSMS, I cannot access the databases (opened in VS), it gives me the following:
the database: databasename is not accessible (objectExplorer)
When you said closing the connection in server explorer do you mean remove it? then will I be able to open the site management again?
|
|

April 5th, 2015, 09:02 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
It seems to be the same issue: one is locking the database so the other can't access it.
Not sure why this isn't working for you. It works fine on my machine. If the problem persists, you should report it t Microsoft.
>> When you said closing the connection in server explorer do you mean remove it?
No, just close it. Right-click the connection in the Server Explorer and choose Close Connection.
Cheers,
Imar
|
|
The Following User Says Thank You to Imar For This Useful Post:
|
|
|
 |
|