SQL Server Management Studio -> New Query -> "is not a valid win32 application"

1

I have been using SQL Server Management Studio for years. Yesterday, when I started hitting "new Query", I would get the following error in pop up form:

"is not a valid win32 application".

I did a lot of googling, and I found this:

http://blog.sqlauthority.com/2009/04/30/sql-server-fix-error-is-not-a-valid-win32-application-exception-from-hresult-0x800700c1/

Which is not at all applicable (but I did set all of my application pools in my IIS to allow 32 bit applications on both the server and my client. I'm not sure how that would make any difference and it didn't). I thought maybe it was a problem with VSSHell, but I have been unable to find any valid information to fix it if it is.

I am using Windows 7 64 bit Ultimate.

My colleagues, who connect to the same SQL Server instance, do not have this issue (so it is a problem with my env).

  • I tried uninstalling and reinstalling.
  • I tried installing SQL Server 2008 R2 Management Studio (and express version).
  • I tried installing SQL Server 2005 Management Studio Express.
  • I even tried the SQL Server 2012 R0 Management Studio. In all, of these, when I click, New Query, I get a pop up that says "is not a valid win32 application".

Please help!

sql-server
ssms
asked on Stack Overflow Jan 5, 2012 by Ryan James • edited Jan 5, 2012 by marc_s

1 Answer

4

Had the same issue - it turns out one of the MS C Runtime libraries got corrupted somehow. I got the name from the exception details. In my case it was MSVCM80.dll in C:\Windows\winsxs\x86_microsoft.vc80.crt_1fc8b3b9a1e18e3b_8.0.50727.6195_none_d09154e044272b9a, that was 0kB.

Once I replaced it with the actual file, all started working again. My advice is - try to locate the faulty file that SQL Studio is trying to open (in my case the same error happened when I tried to start SQL Profiler, and I could trace the exception details there).

Good luck

answered on Stack Overflow Jan 9, 2012 by prezimir

User contributions licensed under CC BY-SA 3.0