JustPaste.it

from os import system
from subprocess import PIPE
import os, subprocess

Pid = os.getpid()
DETACHED_PROCESS = 0x00000008
RunScript = "C:/Folder/Path/VerifyPID.cmd"
Cmd = ["cmd.exe", "/C", RunScript, sys.argv[0], TagName, host, RootPath, str(Pid)]
subprocess.Popen(Cmd, shell=True, stdin=PIPE, stdout=PIPE, stderr=PIPE, creationflags=DETACHED_PROCESS)