Create a new process that will not be my child process ?

Is there a way to create a new process that will not be my child process?
Meaning, that after opening the new process, if I’ll open TaskManager and do “End Process Tree” on the parent process, it will not terminate the child process as well?

Below the code:

Here I create a new process (starting notepad) detached from any other process (CreateFlags = 8).

You can also set other values, for instance if you want the new process to become a new process group parent the you have to set CreateFlags = 512 + 8. Search the WMI docs in MSDN for the details about the possible Win32_Process and Win32_ProcessStartup properties.