Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

schedule auto windows logon and run an application in the foreground

Posted on 2007-03-17
8
Medium Priority
?
534 Views
Last Modified: 2008-02-07
Experts,
Is there any way to schedule a logon to windows server 2003 at a certain time everyday, run an application in the foreground, then logoff by itself ? Note that I do not want to reboot the machine to trigger auto logon every time.

I cannot find any solution that can resolve this.  Is this possible with the combination use of VB script, batch file,  .NET programing and/or windows configuration ?

0
Comment
Question by:jshao825
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 11

Expert Comment

by:AnthonyP9618
ID: 18741660
Will Task Scheduler work?  Task Scheduler will run any CMD, VBS, BAT file you through at it.  I'm don't believe that it will run any .NET scripts though.

http://www.microsoft.com/technet/prodtechnol/windows2000serv/maintain/featusability/tsksched.mspx
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18742083
Sure - but why do you 'have' to hvae it logon?

If you're using W2k3 - it's easy with schtasks...

Schtasks /create /ru system /st 09:00:00 /sc daily /tn DailyTask /tr "C:\path to file\file.exe"
0
 

Author Comment

by:jshao825
ID: 18747854
I have to have W2k3 logon because it is an automated application that opens another application to simulates user clicks.    

I am new to this.  what part of this command tells the W2k3 to logon to the desktop ? I want to see the interaction when programs run

Schtasks /create /ru system /st 09:00:00 /sc daily /tn DailyTask /tr "C:\path to file\file.exe"

I know that    /ru   runs the tasks with the permission of the specified user account in the background, not in the foreground ?


0
Does Your Cloud Backup Use Blockchain Technology?

Blockchain technology has already revolutionized finance thanks to Bitcoin. Now it's disrupting other areas, including the realm of data protection. Learn how blockchain is now being used to authenticate backup files and keep them safe from hackers.

 
LVL 67

Accepted Solution

by:
sirbounty earned 1500 total points
ID: 18747918
No, the above doesn't log on a user.
If you want to accomplish this on a scheduled basis, I only see one method of doing so...

Reboot - system auto-logs on after reboot, runs your script as part of the logon process, then waits until it's near time to run again and reboots.

I'm fairly certain there's no way to schedule a logon and logoff.
You can schedule a logoff to occur at a certain time, but not a subsequent logon without utilizing the auto-logon feature at boot up...
0
 

Author Comment

by:jshao825
ID: 18748314
I am trying to avoid rebotting each time it is schedule to run as well...  

Speaking of logoff.  If the automated application is running for more than 2 hrs, then I want to force a logoff.   How can I achieve that ?
0
 
LVL 67

Assisted Solution

by:sirbounty
sirbounty earned 1500 total points
ID: 18748353
I don't really know much about your application, but there is a native command, logoff, that you could schedule to run at 2 hours after your application.

logoff

will log off the current session...
0
 
LVL 12

Expert Comment

by:RubenvdLinden
ID: 18748584
What is the purpose of simulating the mouse-clicks (there might be a workaround to do the task which performs when you simulate the mouseclicks)?
0
 
LVL 1

Expert Comment

by:laquangthong
ID: 23070477
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After several hours of googling I could not gather any information on this topic. There are several ways of controlling the USB port connected to any storage device. The best example of that is by changing the registry value of "HKEY_LOCAL_MACHINE\S…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…

660 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question