From: John Johnson Date: 2006-05-06T02:21:27+09:00 Subject: Re: win32ole - wait for action to complete You could use WinBatch http://winbatch.com for this. You could even call it from Ruby, if need be. Regards, JJ On 05-May-2006, at 11:30, Rich Hall wrote: > I have a script driving a proprietary Powerbuilder application via > sendkeys. I am trying to time application processing time. My approach > was grab start time, sendkeys to application, grab finish time and > calculate the diff. However, my four seperate timing steps all print > thier complete timestamps before the application is even done > processing > one step. In Marcus Tettmar's MacroScheduler he has a WaitReady > function > that seems to do a good job waiting for the driven event to complete > before continuing execution. I assumed this was making a call to an OLE > function, but have not been able to find such a function. Is there a > way > to make my automation script behave in a synchronous fashion so that I > can use it to get accurate timing? Is there a win32ole function for > this? Or is Macroscheduler using its own function to provide this? > > I would imagine such a routine could be created using win32event, but I > am very new to Ruby and have no idea where to start to build such a > thing. Would appreciate any input you can provide to set me in the > right > direction. > > -- > Posted via http://www.ruby-forum.com/. > > --- "America goes not abroad in search of monsters to destroy." -- John Quincy Adams