Home All Groups Group Topic Archive Search About

Running a Program in 'Silent' Mode

Author
23 Feb 2006 7:40 PM
John R. Dougherty
I have written a VB.NET application, and want to be able to invoke it with
parameters, to run without a user having to interact with it.  I do still
want to see any status messages the program generates (dialog boxes are
suppressed in this mode, but there are still counters, etc. that display).

I am currently invoking the functions of the program from the Form_Load
procedure - then ultimately, the program is closed from here also, when in
this mode.  I am guessing that since the Form_Load never finishes processing
completely, that is why the form is never displayed, and the user never sees
anything.

What do I need to change to allow the form (or some other form, if
necessary) to display on the screen?  Should I be using something like the
Sub Main as the startup entry point, rather than a form?

- Thanks,

JRD

Author
24 Feb 2006 3:19 AM
Rocky
Put the code in the Form Shown event instead of the Load event.


Show quoteHide quote
"John R. Dougherty" <JohnRDoughe***@discussions.microsoft.com> wrote in
message news:7771F0E4-DA5B-409A-9C96-2E25B2D29D10@microsoft.com...
>I have written a VB.NET application, and want to be able to invoke it with
> parameters, to run without a user having to interact with it.  I do still
> want to see any status messages the program generates (dialog boxes are
> suppressed in this mode, but there are still counters, etc. that display).
>
> I am currently invoking the functions of the program from the Form_Load
> procedure - then ultimately, the program is closed from here also, when in
> this mode.  I am guessing that since the Form_Load never finishes
> processing
> completely, that is why the form is never displayed, and the user never
> sees
> anything.
>
> What do I need to change to allow the form (or some other form, if
> necessary) to display on the screen?  Should I be using something like the
> Sub Main as the startup entry point, rather than a form?
>
> - Thanks,
>
> JRD