Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't run Lightswitch 2012 Programm under Windows XP

I've migrated a Lightswitch 2011 project to LS 2012. I start the compiled application by running "vslshost.exe". This works well using Windows 7 (32 and 64 Bit, but when I use Windows XP starting the application fails (vslshost.exe ist not a valid Win32-Application). Before switching to LS 2012 everything went fine.

The application is compiled as desktop application, it depends on a SQL Database which is avaiable and doesn't use the internal ApplicationData database. I can reproduce this on 2 PCs, both having Windows XP up to date.

After looking at vslshosts.exe with ildasm, I'm shure the project was compiled targeting .NET 4.0. So the Framework didn't change with migrating the project to LS 2012.

I wasn't able to find any information regarding this problem. I only came across some issues regarding Windows XP and C++ using VS 2012.

Do you have any information on this?

Thanks in advance!

like image 895
Chake Avatar asked Aug 27 '12 10:08

Chake


1 Answers

I had the same problem, managed to get it working by doing the following. I started up a Visual Studio Command Prompt and ran dumpbin on the executable:

dumpbin  /headers vslshost.exe

dumpbin showed that the sub system version was set to 6 (Vista). Strangely the OS version was set to 4. Following the instructions on this page http://supportxp.com/2012/03/30/editbins-dirty-little-secret/ I used editbin to set the version numbers to 5.1 (XP)

editbin vslshost.exe /SUBSYSTEM:WINDOWS,5.01 /OSVERSION:5.1

Tested it out and my application it working fine on XP so far. I also tried getting the generated installer to work but it failed on a function call to InitializeCriticalSectionEx which doesn't exist in XP.

Or you can deploy it as a desktop application with the services deployed to IIS. That method seems to support XP just fine.

like image 175
Neil Avatar answered Sep 30 '22 05:09

Neil