Ok, This is weird... I just love quirks with .NET 2.0
I create a Window Application in VS IDE 2005
I create a Console... via AllocConsole, all it fine
I create an application context, set the mainform to a form, for
'theContext'
I run the context via Application.Run(theContext)
The minute the Application.Run is done, all events that SHOULD go to
the Console window are blocked and seem to be routed to 'theContext'
mainform.
This does not happen in .NET 1.0, or 1.1.
Since the Console window is a user selectable item, if I do...
Do
DoEvents
Loop While (theMain.IsDisposed)
(Where theMain Closed Event calls Applicatiion.Exit of course)
The console events are NOT trapped and everything works as expected.
If not Console is open, just just call Application.Run(theContext) as
expected.
Anyone has any ideas on how to get events to an attached console to a
Windows application routed to the console window as expected?