English 中文(简体)
从32轨代码中操作64轨可执行
原标题:Running 64-bit executable in System32 from 32-bit code

我正试图从32秒C#(关于64位仲裁员的)中进行迫害,但我却忘记“系统无法找到具体档案”,这很可能是因为 w。 在C:CorysySWOW64 不存在。 系统32确实有档案。 最好的管理办法是什么。 尽可能从法典中删除?

Process p = new Process();
p.StartInfo.Arguments = "-f";
p.StartInfo.FileName = @"C:WindowsSystem32wsqmcons.exe";
p.Start();
p.WaitForExit();
Verify.AreEqual(0, p.ExitCode);
问题回答

你们需要把档案系统改用Wow64 DisableWow64FsRedirection,再用Wow64RevertWow64FsRedirection。

A 64-bit executable file located under %windir%System32 cannot be launched from a 32-bit process, because the file system redirector redirects the path to %windir%SysWOW64. Do not disable redirection to accomplish this; use %windir%Sysnative instead. For more information, see File System Redirector.

Quote from





相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

NSArray s, Primitive types and Boxing Oh My!

I m pretty new to the Objective-C world and I have a long history with .net/C# so naturally I m inclined to use my C# wits. Now here s the question: I feel really inclined to create some type of ...

C# Marshal / Pinvoke CBitmap?

I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class. My import looks like this: [DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr ...

How to Use Ghostscript DLL to convert PDF to PDF/A

How to user GhostScript DLL to convert PDF to PDF/A. I know I kind of have to call the exported function of gsdll32.dll whose name is gsapi_init_with_args, but how do i pass the right arguments? BTW, ...

Linqy no matchy

Maybe it s something I m doing wrong. I m just learning Linq because I m bored. And so far so good. I made a little program and it basically just outputs all matches (foreach) into a label control. ...

热门标签