Windows Photo Viewer terminating with "Com Surrogate" error in Portrait Mode

I'm using Windows 7 Professional SP1 (de, en, jp mui's installed before SP1 setup) with latest Intel HD graphics drivers and latest DirectX (to my knowledge)

On my Tablet PC, where rotating the screen is pretty standard, I have the following problem:

Whenever I rotate the screen to portrait mode and use the Windows Photo Viewer and close said program, It terminates with a "Com Surrogate" error in the "d3d9.dll" module.

Some with that an error of similar kind said it helped to copy over Windows Photo Viewer from an unaffected installation, but I do not have another installation with this MUI setup.

Any idea how to fix that error short of reinstalling Windows?


Solution 1:

d3d9.dll is a component of Directx. I would upgrade your video card drivers, maybe run dxdiag and run some of its tests in both landscape and portrait modes. Beyond that, check if there are any updates to directx itself that might fix it.

Edit: Sorry, didn't see that you already did video drivers and directx upgrades. Perhaps dxdiag might shed some light on the problem.

Solution 2:

Turning off Data Execution Prevention (DEP) on dllhost (the COM surrogate) fixed similar problems for some people:

Execute Control Panel / System / Advanced System settings / Advanced tab / Performance Settings button / Data Execution Prevention tab, and see if it says below : "Your computer's processor supports hardware-based DEP".

If DEP is available, one can :

Turn DEP off : bcdedit.exe /set {current} nx AlwaysOff
Turn DEP on: bcdedit.exe /set {current} nx AlwaysOn

Reboot for the change to take effect.

If turning DEP off does not fix the problem, you should turn it back on.

Solution 3:

This is a typical problem for me it seems, fixing by desperately asking.

This problem persisted for several weeks. As I did not receive an answer by the time I set the bounty, I installed Picasa Photo Viewer and set it to default to work around the symptoms.

I wasn't able to check the answers here for a couple of days, so now I checked it again and and tried Photo Viewer, now it works without a problem. The only difference was the installed Picasa Photo Viewer. I can only assume it fixed something in my dx-lib usage, because it was literally the only thing I did. Even after uninstalling Picasa and using Windows Photo Viewer as a Default Setting does not create the error anymore.

I thank the for the answers for the bounty, but I can't reward it as I can't say that/if it helped.