2007-12-13, 08:49 PM
Firstly - the setPopup call isn't working in this piece of code. Everything else is fine and I see the Logger messages for 'About to set popup' then the one for creating the process....but no popup appears.
Second question - Dvbtr.exe is a command-line program so I get a command prompt appear on screen. How do I start this minimized? I can see the Process.MainWindowHandle property but that is an IntPtr and I can't decide how to use it. Or is there another way?
Cheers,
Brian
Code:
Logger.Verbose("Play invoked");
if (DVBTRadioProc == null)
{
Logger.Verbose("About to set popup");
setPopup(new GBPVRX2.Popups.PopupMessageBox(this, "Starting DVB-T Radio service. Please wait..."));
try
{
Logger.Verbose("About to create process for Dvbtr.exe");
DVBTRadioProc = System.Diagnostics.Process.Start(GBInstallDir + @"plugins\DVB-T Radio\Dvbtr.exe", "529834 8 9018 16384 18560");
}
catch (Exception e)
{
Logger.Verbose(e.ToString());
}
finally
{
setPopup(null);
}
}
Second question - Dvbtr.exe is a command-line program so I get a command prompt appear on screen. How do I start this minimized? I can see the Process.MainWindowHandle property but that is an IntPtr and I can't decide how to use it. Or is there another way?
Cheers,
Brian