Hi,
Could anyone tell me why this is happening, while i am still trying to find any solution on the net. My knowledge about VB6 is very limited. Thanks!!
Our company has a small VB6 program, and so far I have managed to change it to run Acrobat.exe to view PDF files, using the Shell command. Problem happens when I close acrobat.exe (clicking the x at the left coner, or choosing File, exit) - it also closes the VB6 program! while it is supposed to be running until the user closes it.
But if I try to use it to open a txt file with notepad.exe, and close notepad.exe, it is ok - it does not close the VB6 program.
So how come it happens to the acrobat.exe and microsoft excell.exe, but not notepad.exe
extracted code:
success = FindExecutable(fileToOpen, filePath, sRusult)
If (success > 32) Then
pos = InStr(sRusult, Chr$(0))
If pos Then
exeProg = Left$(sRusult, pos - 1)
End If
runExe = Shell(sRusult & " " & filename, vbNormalFocus)
Else
...
...
thanks
wtk