cplau
asked on
Schedule Task at window 2000?
Hi All,
I have used Visual Basic 6.0 to develop a window application before. Now I would like to schedule this application to run at 1:00am everyday.
I know I can do this by adding a schedule task by using "Scheduled Tasks" at control panel.
But I found the application can work only after logging the OS.
I want the application can be run properly if I have power on my PC without log in.
How can I solve this problem?
If I run my application as a service, can this solve my problem?
Can a service be scheduled to run periodically?
Please advice. Thanks!
I have used Visual Basic 6.0 to develop a window application before. Now I would like to schedule this application to run at 1:00am everyday.
I know I can do this by adding a schedule task by using "Scheduled Tasks" at control panel.
But I found the application can work only after logging the OS.
I want the application can be run properly if I have power on my PC without log in.
How can I solve this problem?
If I run my application as a service, can this solve my problem?
Can a service be scheduled to run periodically?
Please advice. Thanks!
Your application should normally be running even if you are not logged in. A mistake often done by programmers is that resources (mapped drives, printers, ...) are not available when not logged in.
Start by creating an application that does nothing and schedule it. You should see that the application will be launched. Then add your code to this application with a lot of tracing (wrtiting to a .log file on the C: drive) to know exactly where the application is going and where it is stopping.
Start by creating an application that does nothing and schedule it. You should see that the application will be launched. Then add your code to this application with a lot of tracing (wrtiting to a .log file on the C: drive) to know exactly where the application is going and where it is stopping.
ASKER
Hi All,
If I run my application as a service, can I schedule it to run periodically?
I know I can use Scheduled Task to run an exe file periodically. How about a service?
Thanks!
If I run my application as a service, can I schedule it to run periodically?
I know I can use Scheduled Task to run an exe file periodically. How about a service?
Thanks!
A service is yet another thing and have more limits! Also, Windows Services should be written in VB.Net to be easier.
Did you trace your application yet?
ASKER
Dear emoreau,
My application needs to use a network drive.
Can I map a network drive without log in the OS?
Further, please advise whether a service can be scheduled or not?
Thanks!
My application needs to use a network drive.
Can I map a network drive without log in the OS?
Further, please advise whether a service can be scheduled or not?
Thanks!
>>Can I map a network drive without log in the OS?
If you can give credentials.
can't you use a URN: \\servername\sharename\fol der\
If you can give credentials.
can't you use a URN: \\servername\sharename\fol
ASKER
Dear emoreau,
Could you give me the source code to use URN to map a network drive?
Thanks!
Could you give me the source code to use URN to map a network drive?
Thanks!
ASKER
Dear emoreau,
The most important question:
A service at window 2000 can be scheduled to run at a specified
time or not?
Thanks!
The most important question:
A service at window 2000 can be scheduled to run at a specified
time or not?
Thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
There is a utility called srvany that will probably work for you. It is available as a download at Microsofts web site