开发者

How can I start ServerManager.msc on a 64bit Windows Server 2008 from a 32bit .NET App?

I have the follow开发者_C百科ing scenario:

- 64bit Windows Server 2008.

- 32bit .NET application (needs to be x86 for various reasons).

- I need to start ServerManager.msc from my .NET application.

When using Process.Start("ServerManager.msc"), I get the following exception:

System.ComponentModel.Win32Exception.

Message="The system cannot find the file specified".

On a 32bit Windows Server 2008 the code works fine...

I tried to inlcude the full path to ServerManager.msc, but that does not help either.

Also no difference if running with or without admin privileges.

Any ideas?


On WOW64, if a 32-bit application refers to C:\Windows\System32; the operating system transparently remaps this to C:\Windows\SysWOW64 (which is where the 32-bit stuff lives).

As a 32-bit application on Win64, you need to specify the full path as %SYSTEMROOT%\SysNative\ServerManager.msc.

SysNative doesn't exist on x86 Windows (there's no reverse mapping, at least on Win7 Ultimate), so you'll need to figure out whether you're on x86 or x64 first.


Please use depends.exe to find out which file/dll is missing.

If it is using an x86 native dll/library which is compiled in newer version of VC++ Runtime. Install the latest VC++ runtime on the 2008 server. Latest I believe is 2008 SP1.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜