i wan to create a program that can get the application name
i can start the program but cant get the program name
<br/><br/>
a = Process.Start("calc").Handle<br/>
MsgBox(a)<br/>
MsgBox(Process.GetProcessById(a).ToSt</ br>ring)<br/>
<br/>
it show Process with an Id of 1796 is not running, but the program already opened
Handle!=Id, andToString()won’t give you the process name:Displays a process ID in one message box, then “calc” in the next.
If you had Option Strict On, you’d have received a warning already about your mixup between Handle and Id, since
Handlereturns anIntPtr, butGetProcessByIdexpects anInteger.