Frodolon
❔ Using STARTUPINFOEXW on PInvoke.CreateProcess - how to move from ref / out to pointer?
I'm using CsWin32 but I'm having trouble calling
PInvoke.CreateProcess
using a STARTUPINFOEXW
instead of a STARTUPINFOW
at argument 9 (in info
).
Looking at https://github.com/microsoft/CsWin32/issues/917 it says to instead of doing
I should use the variant using pointers... but I can't seem to figure out how to correctly refer to my Span<char> cmdLine = stackalloc char[execPath.Length];
and my STARTUPINFOEXW info = new STARTUPINFOEXW()
using pointers or replacing out var
with pointers17 replies