VB .Net 2003, .Net Framework 1.1, Windows XP Pro SP1
I've written a console application which I run as a scheduled task. How do
I return an exit status value (or string) from the application so that the
status is displayed in the Status column of the Scheduled Tasks window?
I've tried the following methods, and the console app definitely runs (as
shown by the Last Run Time in the Scheduled Tasks window), however the
Status column is blank.
Sub Main()
Dim ExitStatus As Integer = 10
Environment.Exi tCode = ExitStatus
Environment.Exi t(ExitStatus)
End Sub
Function Main() As Integer
Dim ExitStatus As Integer = 10
Return ExitStatus
End Function
Thanks for any help or info on this. 3 11874
"John Williams" <jo************ ******@NOhotmai lSPAM.com> wrote in message
news:OH******** ******@TK2MSFTN GP12.phx.gbl... VB .Net 2003, .Net Framework 1.1, Windows XP Pro SP1 I've tried the following methods, and the console app definitely runs (as shown by the Last Run Time in the Scheduled Tasks window), however the Status column is blank.
The exit code returned is actually shown in the Last Result column. Maybe
the Status is there for the Task Scheduler to set and cannot be set directly
by the application?
On 2004-10-04, John Williams <jo************ ******@NOhotmai lSPAM.com> wrote: "John Williams" <jo************ ******@NOhotmai lSPAM.com> wrote in message news:OH******** ******@TK2MSFTN GP12.phx.gbl... VB .Net 2003, .Net Framework 1.1, Windows XP Pro SP1 I've tried the following methods, and the console app definitely runs (as shown by the Last Run Time in the Scheduled Tasks window), however the Status column is blank.
The exit code returned is actually shown in the Last Result column. Maybe the Status is there for the Task Scheduler to set and cannot be set directly by the application?
I believe the status column will tell you if the application is running
or not... In other words, if you open the task sheduler while that
application is running, the status column will say Running.
--
Tom Shelton [MVP]
"Tom Shelton" <to*@YOUKNOWTHE DRILLmtogden.co m> wrote in message
news:uC******** ******@TK2MSFTN GP11.phx.gbl... I believe the status column will tell you if the application is running or not... In other words, if you open the task sheduler while that application is running, the status column will say Running.
Thanks for your reply, Tom. I understand what the Status column does now. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Christina |
last post by:
Dear All,
How can I pop up the windows task scheduler inside of my .net application?
Such as I have a button called Schedule Now, after clicking it, the Add
Scheduled Task window will pop up, just like clicking from Control Panel ->
Scheduled Task -> Add Scheduled Task. Appreciate ahead for any of your
suggestions. Thanks.
|
by: steve |
last post by:
it seems that i'm required to hit ENTER in order to exit my console app.
this is not very desirable since the app is intended to run as a scheduled
task. sub main creates an object that synchronizes some information via the
internet. the object creates a thread responsible for the communication and
the display of messages to the console. when the object gets a message that
the thread has completed its work (via a raised event) then the...
|
by: newbie |
last post by:
Hi all,
http://www.aswin.be/nictransfer.JPG
How can I get these numbers with VB.NET ?
I thought somewhere in WMI but I can't find them.
Thank you,
Aswin
|
by: asadikhan |
last post by:
I have written a console application that clears out some folders. I
want this application to run as a Windows Service (not a scheduled
task). What is the easiest way to convert this console application into
a Windows Service using Visual Studio .Net?
Asad
|
by: Nicol |
last post by:
Hi,
I have created a console application in c#.net. I also scheduled it
in the windows scheduler. In the scheduled task i will specify the command
line arguments. When I say "Run", I am getting the command window, which I
dont want. I need to run my application in silent mode. My system is windows
2003 server.
Please help me in this.
Thanks
| |
by: Krish |
last post by:
I want to develop and application that run periodically in the server
machine. Now Should I go for a windows service or just create a Console
application and schedule it using the windows Task Scheduler.
What are the advantages and disadvantages of each approach.
Thanks
Krish
|
by: kplkumar |
last post by:
Hi all
I am fairly new to windows scheduler.
I have an .exe console application that needs to be run 1st of every
month. I created a scheduled task in Windows Schduler and called
the .exe.
The application is supposed to pull some report data and make a
webservice call to sent out this data.
|
by: Tatter |
last post by:
I have a simple .NET 1.1 console application, written with Visual Studio .NET 2003, that needs to be run on a Windows XP system as a scheduled task. When run on its own, the program executes with no errors. When run as a scheduled task on a computer with debugging tools installed, it runs with no errors.
When run as a scheduled task on a computer with no debugging tools installed, namely the Windows XP system it is supposed to be run on, it...
|
by: =?Utf-8?B?VGVycmFuY2U=?= |
last post by:
Good Afternoon:
I have two questions I was hoping someone can help me with.
1. I've created a app that creates a xml file; the project was constructed
as a console window. I want to know is there anyway to suppress the console
window from showing? One of the options is I have is to generate the xml file
without showing the console window. Even though I'm not calling the Console
it still flashes. Any suggestions. I plan on running this...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |