Solved

Timing

Posted on 2003-11-19
13
736 Views
Last Modified: 2010-05-01
Hi

I'm using sendkey to fill some form field. Unfortunately sendkey is too fast thats why the form is not filled properly. So tried to add a 'sleep(ms)' command before each sendkey command. Also this give me troubles, maybe because kernel. Now I'm trying to replace the sleep function with 'Wait' (which is working) but lowest level is in seconds and not in ms (Application.wait(1000) not working). Is there another way to solve this problem?

Thx mg
0
Comment
Question by:mgroyal
  • 5
  • 4
13 Comments
 
LVL 9

Expert Comment

by:TooKoolKris
ID: 9779743
Try putting your sleep commands in after each sendkey instead of before it. I normally give 2000ms for each keystroke.
0
 
LVL 1

Author Comment

by:mgroyal
ID: 9779838
I can't use the Sleep Function because the background process should go on...
0
 
LVL 1

Author Comment

by:mgroyal
ID: 9779899
increased to 150 for proper solution
0
 
LVL 9

Expert Comment

by:TooKoolKris
ID: 9779989
What background process, you said yourself that you were wanting the application to wait. If you want a seperate process then create one that is independent of the sendkey process.
0
 
LVL 1

Author Comment

by:mgroyal
ID: 9780084
I'm sending data with sendkey to a 'report request'. The report request is a macro in excel and get the data from oracle for displaying them in excel. There're several bg-processes like db-connection etc. Anyway when I'm using sleep function the form is freezing (conflict?) for about 5 seconds and after data nothing happens (Also when I use sleep after sendkeys). When I'm using the wait function it's working (wait does not stop the backround processes) but I can't wait 1 second for every key which I sending. I need ms...
0
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.

 
LVL 9

Accepted Solution

by:
TooKoolKris earned 150 total points
ID: 9780180
Oh, I see what you mean now. This is a long shot but see it the wait function will accept a decimal like .5
0
 
LVL 1

Author Comment

by:mgroyal
ID: 9780190
solved....
0
 
LVL 9

Expert Comment

by:TooKoolKris
ID: 9781178
how so?
0
 
LVL 1

Expert Comment

by:anaadoul
ID: 9805100
please close the question or delete it

---------------------------------
There Are 10 Kind OF People
Those Who Understands Binary AND Those Who Don't
0
 
LVL 9

Expert Comment

by:TooKoolKris
ID: 9811886
Yea, and along with your solved solution how about posting why I should accept fewer points while your at it.

Thanks
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

Suggested Solutions

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

920 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

12 Experts available now in Live!

Get 1:1 Help Now