Solved

Shouldn't 'sendkeys' be enough to stop inactivity?

Posted on 2006-10-19
6
244 Views
Last Modified: 2010-04-23
I have a scheduled task that kicks off when I'm "idle".  But I only want it to run at a certain time.  There's no way to accomplish what I want with the task, without having it run 'each' time I'm idle throughout the day.
So, I 'tried' to create a simple app that would use sendkeys to hit the insert key for me every few minutes.
Doesn't appear to be working though - any ideas why not?

Form_Load
  tmr.Start

TimerFired
  Sendkeys.SendWait("{INSERT}")
  Sendkeys.SendWait("{INSERT}")
End Sub

That's about all there is to it...(I didn't want to leave 'insert' off...that's why it's there twice)
0
Comment
Question by:sirbounty
6 Comments
 
LVL 13

Expert Comment

by:newyuppie
ID: 17767174
why dont you put a system time check, if its not what you want, exit the sub, otherwise, check if its idle and run the loop.

ny
0
 
LVL 10

Expert Comment

by:gangwisch
ID: 17767179
what you need to do is:
appactivate "internet explorer"
sendkeys.send("http://")
sendkeys.send("{enter}")
but i do think that
you should try doing
sendkeys.send("{INS}")

good luck
0
 
LVL 67

Author Comment

by:sirbounty
ID: 17767188
So, I can't sendkeys to my form? (since it's already "there")?
I didn't want to have to load IE, or any other app - I thought I could accomplish this within my program...
0
 
LVL 67

Author Comment

by:sirbounty
ID: 17817492
I can sendkeys to my form - I got this working using me.bringtofront
0
 
LVL 1

Accepted Solution

by:
DarthMod earned 0 total points
ID: 17849770
Closed, 500 points refunded.
DarthMod
Community Support Moderator
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …

863 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

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now