I have this code:

Code:
 Dim pinfo As New ProcessStartInfo("cmd")
        Dim p As Process = System.Diagnostics.Process.Start(pinfo)


        MsgBox(p.MainWindowHandle)
Nothing to crazy right. Well if I just run it I get 0 for the MainWindowHandle, however if I step through it I actually get a value. What's the deal? Running .NET 2005.