PC Review


Reply
Thread Tools Rate Thread

exe for scheduled task

 
 
Curious
Guest
Posts: n/a
 
      21st May 2009
I want to create a C#.NET project that will have an .exe executable to
be launched by Task Manager on a set schedule.

Is "Console Application" the right type for the C#.NET project?
 
Reply With Quote
 
 
 
 
Mr. Arnold
Guest
Posts: n/a
 
      22nd May 2009

"Curious" <(E-Mail Removed)> wrote in message
news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>I want to create a C#.NET project that will have an .exe executable to
> be launched by Task Manager on a set schedule.
>
> Is "Console Application" the right type for the C#.NET project?


That's one of two you could use. The other one is a Windows form application
that has no controls on the form, a blank form. The code to start the
application would be in the From-Load(). You would hide the form at
Form.Load() before the processing took place, and then you do a
Form-Unload() after processing is complete to end the program, which you can
use the Task Secdular.


__________ Information from ESET NOD32 Antivirus, version of virus signature database 4095 (20090521) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com



 
Reply With Quote
 
Mr. Arnold
Guest
Posts: n/a
 
      22nd May 2009

"Curious" <(E-Mail Removed)> wrote in message
news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>I want to create a C#.NET project that will have an .exe executable to
> be launched by Task Manager on a set schedule.
>
> Is "Console Application" the right type for the C#.NET project?


That's one of two you could use. The other one is a Windows form application
that has no controls on the form, a blank form. The code to start the
application would be in the From-Load(). You would hide the form at
Form.Load() before the processing took place, and then you do a
Form-Unload() after processing is complete to end the program, which you can
use the Task Secdular.


__________ Information from ESET NOD32 Antivirus, version of virus signature database 4095 (20090521) __________

The message was checked by ESET NOD32 Antivirus.

http://www.eset.com



 
Reply With Quote
 
Curious
Guest
Posts: n/a
 
      22nd May 2009
On May 21, 7:32*pm, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> "Curious" <fir5tsi...@yahoo.com> wrote in message
>
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>
> >I want to create a C#.NET project that will have an .exe executable to
> > be launched by Task Manager on a set schedule.

>
> > Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form application
> that has no controls on the form, a blank form. The code to start the
> application would be in the From-Load(). You would hide the form at
> Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you can
> use the Task Secdular.
>
> __________ Information from ESET NOD32 Antivirus, version of virus signature database 4095 (20090521) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com


Thanks!
 
Reply With Quote
 
Curious
Guest
Posts: n/a
 
      22nd May 2009
On May 21, 7:32*pm, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> "Curious" <fir5tsi...@yahoo.com> wrote in message
>
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>
> >I want to create a C#.NET project that will have an .exe executable to
> > be launched by Task Manager on a set schedule.

>
> > Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form application
> that has no controls on the form, a blank form. The code to start the
> application would be in the From-Load(). You would hide the form at
> Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you can
> use the Task Secdular.
>
> __________ Information from ESET NOD32 Antivirus, version of virus signature database 4095 (20090521) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com


Thanks!
 
Reply With Quote
 
Miro
Guest
Posts: n/a
 
      22nd May 2009
I agree with Mr. Arnold.

I would use a form, and set the transparency to 100%.
(invisible form).

You never know later if you want to add your own little monitors and debugs
to it during runtime.

Miro

"Curious" <(E-Mail Removed)> wrote in message
news:1bc64f6d-b01f-4e9d-b190-(E-Mail Removed)...
On May 21, 7:32 pm, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> "Curious" <fir5tsi...@yahoo.com> wrote in message
>
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>
> >I want to create a C#.NET project that will have an .exe executable to
> > be launched by Task Manager on a set schedule.

>
> > Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form
> application
> that has no controls on the form, a blank form. The code to start the
> application would be in the From-Load(). You would hide the form at
> Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you
> can
> use the Task Secdular.
>
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4095 (20090521) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com


Thanks!

 
Reply With Quote
 
Miro
Guest
Posts: n/a
 
      22nd May 2009
I agree with Mr. Arnold.

I would use a form, and set the transparency to 100%.
(invisible form).

You never know later if you want to add your own little monitors and debugs
to it during runtime.

Miro

"Curious" <(E-Mail Removed)> wrote in message
news:1bc64f6d-b01f-4e9d-b190-(E-Mail Removed)...
On May 21, 7:32 pm, "Mr. Arnold" <MR. Arn...@Arnold.com> wrote:
> "Curious" <fir5tsi...@yahoo.com> wrote in message
>
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>
> >I want to create a C#.NET project that will have an .exe executable to
> > be launched by Task Manager on a set schedule.

>
> > Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form
> application
> that has no controls on the form, a blank form. The code to start the
> application would be in the From-Load(). You would hide the form at
> Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you
> can
> use the Task Secdular.
>
> __________ Information from ESET NOD32 Antivirus, version of virus
> signature database 4095 (20090521) __________
>
> The message was checked by ESET NOD32 Antivirus.
>
> http://www.eset.com


Thanks!

 
Reply With Quote
 
Gloops
Guest
Posts: n/a
 
      23rd May 2009
Mr. Arnold a écrit, le 22/05/2009 01:32 :
>
> "Curious" <(E-Mail Removed)> wrote in message
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>> I want to create a C#.NET project that will have an .exe executable to
>> be launched by Task Manager on a set schedule.
>>
>> Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form
> application that has no controls on the form, a blank form. The code to
> start the application would be in the From-Load(). You would hide the
> form at Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you
> can use the Task Secdular.
>



Hello,

You also have another solution. In program.cs in a Windows application,
you find the instruction
Application.Run(new Form1());

If you quote that instruction so that it is not excuted, the form is not
loaded, so you do not even have to unload it, and you can put your
instructions underneath.

Supposing one day you come to need an interface, you can unquote the
instruction that launches the form -and pay attention if you need it
before or after the other instructions.

Of course, supposing the program reaches a certain size, it is important
to remember to keep it a clear structure, for instance by writing static
methods in classes.

 
Reply With Quote
 
Gloops
Guest
Posts: n/a
 
      23rd May 2009
Mr. Arnold a écrit, le 22/05/2009 01:32 :
>
> "Curious" <(E-Mail Removed)> wrote in message
> news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
>> I want to create a C#.NET project that will have an .exe executable to
>> be launched by Task Manager on a set schedule.
>>
>> Is "Console Application" the right type for the C#.NET project?

>
> That's one of two you could use. The other one is a Windows form
> application that has no controls on the form, a blank form. The code to
> start the application would be in the From-Load(). You would hide the
> form at Form.Load() before the processing took place, and then you do a
> Form-Unload() after processing is complete to end the program, which you
> can use the Task Secdular.
>



Hello,

You also have another solution. In program.cs in a Windows application,
you find the instruction
Application.Run(new Form1());

If you quote that instruction so that it is not excuted, the form is not
loaded, so you do not even have to unload it, and you can put your
instructions underneath.

Supposing one day you come to need an interface, you can unquote the
instruction that launches the form -and pay attention if you need it
before or after the other instructions.

Of course, supposing the program reaches a certain size, it is important
to remember to keep it a clear structure, for instance by writing static
methods in classes.

 
Reply With Quote
 
Curious
Guest
Posts: n/a
 
      26th May 2009
On May 23, 5:40*am, Gloops <glo...@invalid.zailes.org> wrote:
> Mr. Arnold a écrit, le 22/05/2009 01:32 :
>
>
>
> > "Curious" <fir5tsi...@yahoo.com> wrote in message
> >news:2af0cd86-69b8-42fa-8d3e-(E-Mail Removed)...
> >> I want to create a C#.NET project that will have an .exe executable to
> >> be launched by Task Manager on a set schedule.

>
> >> Is "Console Application" the right type for the C#.NET project?

>
> > That's one of two you could use. The other one is a Windows form
> > application that has no controls on the form, a blank form. The code to
> > start the application would be in the From-Load(). You would hide the
> > form at Form.Load() before the processing took place, and then you do a
> > Form-Unload() after processing is complete to end the program, which you
> > can use the Task Secdular.

>
> Hello,
>
> You also have another solution. In program.cs in a Windows application,
> you find the instruction
> Application.Run(new Form1());
>
> If you quote that instruction so that it is not excuted, the form is not
> loaded, so you do not even have to unload it, and you can put your
> instructions underneath.
>
> Supposing one day you come to need an interface, you can unquote the
> instruction that launches the form -and pay attention if you need it
> before or after the other instructions.
>
> Of course, supposing the program reaches a certain size, it is important
> to remember to keep it a clear structure, for instance by writing static
> methods in classes.


Way to go!
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
What happens if a scheduled task is scheduled to start, but theprevious task execution is still running? joe.carr@gmail.com Windows XP General 1 17th Dec 2007 08:32 PM
How to Read Scheduled Task Last Result from Registry for a task Sakthi Windows XP General 1 20th Jul 2007 07:45 AM
W2K Scheduled Task: Run interactive task when runas another user yatfanho Windows XP 4 20th May 2005 03:42 AM
Add Scheduled Task wizard in Scheduled Tasks won't run =?Utf-8?B?U01GYWlzb24=?= Microsoft Windows 2000 4 12th May 2005 01:26 AM
On startup get failed to run scheduled task for user account, but there is no task scheduled! kifoghorn Windows XP Help 0 18th Apr 2005 08:05 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:41 PM.