sPROCESS_INFO = PROCESS_INFO(0, 0, 0, 0) ret = CreateProcess(CStr("\windows\iexplore.exe"), CStr("\My Documents\mike\test.htm"), 0, 0, 0, 0, 0, 0, 0, sPROCESS_INFO) getPROCESS_INFO sPROCESS_INFO, hProcess, hThread, dwProcessId, dwThreadId 'hThread = TerminateProcess(hProcess, 0) 'vill terminate running app If ret > 0 Then CloseHandle (hProcess) 'close handle << so to find this hProcess it took me ....the lines below Public Sub getPROCESS_INFO(ByVal sPROCESS_INFORMATION As String, _ ByRef hProcess As Long, ByRef hThread As Long, _ ByRef dwProcessId As Long, ByRef dwThreadId As Long) ' memory-formatted String back to Long Integer. hProcess = MemStringToLong(MidB(sPROCESS_INFORMATION, 1, 4)) hThread = MemStringToLong(MidB(sPROCESS_INFORMATION, 5, 4)) dwProcessId = MemStringToLong(MidB(sPROCESS_INFORMATION, 9, 4)) dwThreadId = MemStringToLong(MidB(sPROCESS_INFORMATION, 13, 4)) End Sub Public Function PROCESS_INFO(hProcess As Long, hThread As Long, _ dwProcessId As Long, dwThreadId As Long) As String ' inbound Long Integers to a memory storage String format. PROCESS_INFO = LongToMemoryString(hProcess) & _ LongToMemoryString(hThread) & _ LongToMemoryString(dwProcessId) & _ LongToMemoryString(dwThreadId) End Function Public Function MemStringToLong(StringIn As String) As Long On Error Resume Next Dim hVal As String ' String back to Long Integer. Dim i As Long For i = 4 To 1 Step -1 hVal = hVal & Hex(AscB(MidB(StringIn, i, 1))) Next i ' Return Long Integer value. MemStringToLong = CLng("&H" & hVal) End Function Public Function LongToMemoryString(ByVal lInputValue As Long) As String Dim hVal As String Dim n As Long Dim i As Long ' Convert to HEX value. hVal = Hex(lInputValue) ' Check to see if it is not zero. If hVal <> "0" Then n = Len(hVal) If n < 8 Then hVal = String(8 - n, "0") & hVal End If ' Use ChrB to rebuild Bytes. For i = 7 To 1 Step -2 LongToMemoryString = LongToMemoryString & _ ChrB(CInt("&H" & Mid(hVal, i, 2))) Next i Else ' return zeros. ' Use ChrB to build Bytes. LongToMemoryString = ChrB(CInt("&H00")) LongToMemoryString = LongToMemoryString & ChrB(CInt("&H00")) LongToMemoryString = LongToMemoryString & ChrB(CInt("&H00")) LongToMemoryString = LongToMemoryString & ChrB(CInt("&H00")) End If End Function