'DELAY TACTIC #1
Declare Sub Sleep Lib "kernel32" Alias "Sleep" (ByVal dwMilliseconds As Long)
Sub Sleep()
Sleep 1000
End Sub
'DELAY TACTIC #2
Sub MyMainMacro()
Application.OnTime When:=Now + TimeValue("00:00:1"), Name:="PostSleep"
End Sub
Public Sub PostSleep()
' do nothing after sleep
End Sub
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
From novice to tech pro — start learning today.
I'm not as up as I should be on the code you're trying in order to help you to the degree that you need to be helped. I mean I could be, if I could find the time, but I can't. So if we can stay with generalizations, I might at least be able to spark some notion in you which could get you there...
...and the question I have which may do just that is this: After you've pasted something, is there any way to verify, using code, that said pasting succeeded before moving onto the next copy-and-paste?
If so, then that would be better than timers. With timers, you're just guessing... operating in the blind... hoping the end-user's machine on which the code may run will be as fast as yours, or have as much RAM (or have a little in it)... that sort of thing. But when you can perform a task with code, then verify that it happened before moving on to the next task (and have a plan "B" piece of code if the verification fails), then it doesn't matter how fast the code runs, or well the machine is able to keep up with whatever are the tasks.
Thoughts?