View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
reachthepalace[_4_] reachthepalace[_4_] is offline
external usenet poster
 
Posts: 1
Default sendkey method for forms


I have a sub that calls a form. The form has some code to check data
select range etc. I want the sub or form to click "OK" command once i
does the checks without user interference.

From the forum, I got the key as
Application.sendkeys("{Enter}")

But where do I put this line? In the form or in the sub calling th
form?

Sub calls the form
Form is shown
Form executes whatever, required fields are populated
<code executes the OK
control returns to the sub
does a bunch of things

Thanks all for the hel

--
reachthepalac
-----------------------------------------------------------------------
reachthepalace's Profile: http://www.excelforum.com/member.php...fo&userid=3172
View this thread: http://www.excelforum.com/showthread.php?threadid=53344