Re: VB.Net Console app needs timer
- From: "Scott M." <quanker@xxxxxxxxx>
- Date: Thu, 05 Jul 2007 19:52:54 -0000
On Jul 5, 3:08 pm, "Al G" <agerha...@xxxxxxxxxxx> wrote:
"Scott M." <quan...@xxxxxxxxx> wrote in message
news:1183661709.081614.76360@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
On Jul 5, 2:41 pm, "Egghead" <robertlo@xxxxxxxxxx> wrote:
Why not use the scheduler?
--
cheers,
RL"Scott M." <quan...@xxxxxxxxx> wrote in message
news:1183656651.419053.180430@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
I'm an old VB6 guy just starting out in VB.Net using Visual Studio
Express. I want to build a simple console app that will create a
simple text file every 10 minutes. I can create the file OK, but how
do I put in the timer so that I can write the file on schedule? The
idea behind this project is to help me monitor remote computers in a
production environment to make sure that they are up and running. I
currently synchronize files on them using DriveHQ.com. What I want to
do is be able to examine my DriveHQ account and see, from what I write
in the text file, that my systems are up and running.
The app coding so far is this;
'create file
My.Computer.FileSystem.WriteAllText("C:\Test.txt",
String.Empty, False)
'write file header
My.Computer.FileSystem.WriteAllText("C:\Test.txt", "Heartbeat
File" & vbCrLf, True)
'write current date/time to file
My.Computer.FileSystem.WriteAllText("C:\Test.txt", Now() &
vbCrLf, True)
Scott- Hide quoted text -
- Show quoted text -
I am too new to VB2005 to know how to use it. Can you give me a hint?
Start Menu > Settings > Control Panel > Scheduled Tasks > Add Task...
Al G- Hide quoted text -
- Show quoted text -
Oh, that scheduler. I can use it to launch my tiny program, but I need
the program to write out my heartbeat file every ten minutes. I could
just as easily put my program in the startup folder.
.
- Follow-Ups:
- Re: VB.Net Console app needs timer
- From: Chris Dunaway
- Re: VB.Net Console app needs timer
- From: Mr. Arnold
- Re: VB.Net Console app needs timer
- References:
- VB.Net Console app needs timer
- From: Scott M.
- Re: VB.Net Console app needs timer
- From: Egghead
- Re: VB.Net Console app needs timer
- From: Scott M.
- Re: VB.Net Console app needs timer
- From: Al G
- VB.Net Console app needs timer
- Prev by Date: Re: Accessing a control if its name is in a string variable
- Next by Date: Encrypting large amounts of data
- Previous by thread: Re: VB.Net Console app needs timer
- Next by thread: Re: VB.Net Console app needs timer
- Index(es):
Relevant Pages
|
Loading