PDA

View Full Version : Repeating a VBA program


Thawlro
26-10-2004, 07:46 PM
I have a need to use the Right-click Mouse function to repeat commands. At the present, only the VBA run is placed on the command line (EX: -VBArun) and the command does not repeat. Is there a way to make this work?

The bottom line is I want to be able to run a VBA program and then Right-Click on mouse, repeating the same VBA program.


Thanks for our time.

hendie
27-10-2004, 07:31 AM
Use a lisp routine to call your VBA program.

;;; www.resourcecad.com

(defun C:CDEV (/ oldecho)
(setq oldecho (getvar "cmdecho"))
(setvar "cmdecho" 0)
(command "-vbarun" "C:/Program Files/RCIapps/Cdev.dvb!ConeMod.ShowCone")
(setvar "cmdecho" oldecho)
(princ)
)

Thawlro
27-10-2004, 12:59 PM
THank you for your help. I didn't want to have to do it this way, but it seems like everyone has the same idea. You been a great help.

YosSa
27-10-2004, 03:21 PM
cant it be done in the acad.pgp ?!?!?
Can you call a lisp cq VBA file in acad.pgp ??

Dont have time to try it now.