xgibbousx
Aerospace
- Jul 3, 2007
- 5
Hey everybody,
I'm writing a macro that uses the "assemble" command, and it requires me to sendkeys to CATIA, since assemble always brings up a dialog box. I'm calling a .vbs to do the sendkeys, since sendkeys doesn't work in the .catvba. The problem is, when I use assemble, the command takes quite a while to execute. Unfortunately, the .vbs continues to send commands to CATIA, so many of the sendkeys aren't received while assemble is running. I used a pause for a set amount of time, which works, but it seems like a very inefficient and sloppy way to do this. Is there any way to somehow determine if CATIA is finished executing its commands? Is there anyway to call another CATIA vba, or somehow make the vba wait for the vbs to finish?
I'm writing a macro that uses the "assemble" command, and it requires me to sendkeys to CATIA, since assemble always brings up a dialog box. I'm calling a .vbs to do the sendkeys, since sendkeys doesn't work in the .catvba. The problem is, when I use assemble, the command takes quite a while to execute. Unfortunately, the .vbs continues to send commands to CATIA, so many of the sendkeys aren't received while assemble is running. I used a pause for a set amount of time, which works, but it seems like a very inefficient and sloppy way to do this. Is there any way to somehow determine if CATIA is finished executing its commands? Is there anyway to call another CATIA vba, or somehow make the vba wait for the vbs to finish?