Author Topic: Make up your freaking mind  (Read 1343 times)

0 Members and 1 Guest are viewing this topic.

Bob Wahr

  • Guest
Make up your freaking mind
« on: June 09, 2006, 04:40:37 PM »
Ran across this article a while back, bookmarked it for later comment.  It's later, I'm commenting.

Article
Quote from: "Article Title and Subtitle
Load and Run VBA Macros Using Straight VBA 
 
 Contrary to popular belief, the process doesn't require AutoLISP
Woohoo!  This is great, can't wait to see how to do it. 
Quote
Kick it Up Another Notch
The next kicker is adding a command-line definition directly from our DVB file. Instead of having a LISP file do it, you can combine a LISP statement and the SendCommand to accommodate this option. Anyone familiar with my posts on the newsgroups should know I don't advocate using the SendCommand or mixing programming languages. However, in this case, there's no better solution available unless you do it in ARX or NET. So, here is the LISP statement you would normally place within a LISP file or attach to a toolbar button:

(Defun C:VBAT ()
  (vl-vbarun "c:/{your install path}/ Custom_menu.dvb!CreateVBAToolBar"))
OK, how is this not using AutoLISP.  This is like saying that if I load and execute an ARX from inside a VBA routine that I can do whatever it is that the ARX does "in VBA without using ARX."

Jeff_M

  • King Gator
  • Posts: 3979
  • C3D user & customizer
Re: Make up your freaking mind
« Reply #1 on: June 09, 2006, 04:55:39 PM »
While the author's choice of words may be off, this does have potential in that you don't have to maintain separate files (lsp/dvb).

Had they worded thusly:
Quote from: "Article Title and Subtitle
Load and Run VBA Macros Using Straight VBA 
 
 Contrary to popular belief, the process doesn't require a separate AutoLISP file
it might have made a bit more sense.

Bob Wahr

  • Guest
Re: Make up your freaking mind
« Reply #2 on: June 09, 2006, 05:05:52 PM »
It's still not technically straight VBA but yes.  Whether you load them with an ACAD.DVB or an ACAD.LSP, you still are loding them using lisp in a separate file.