Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations GregLocock on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Loading a dvb file from a button 1

Status
Not open for further replies.

shadow

Computer
Mar 1, 2001
321
Ok i found this really cool gui calculator program online that runs inside of autocad but the readme.txt is all in german and the little i know how to translate says use this macro (command "_vbarun" "calculator")for a button to start the dvb file but one thing it doesnt load the file and the only way i can load it is to goto appload and select the file and load it or load it in the startup suit so it loads automatically but the problem ther is im trying to have it initally load at the press of the button so if anyone knows how to set up macros or knows lisp and can get a dvb file to load with a button macro ill be willing to share this sweet calc prog

PS it inserts the calculation into the drawing
 
Replies continue below

Recommended for you

ohh also i know about the lisp command to add to a macro that will allow the loading of lisp files
(load "mylispfile.lsp")
but if i apply it to my dvb file i get this on the command line
(load "calculator.dvb") ; error: bad character read (octal): 21
if anyone has an idea about this let me know
remember share the wealth of knowlege i know i do
 
If you want to load this project file every time you start AutoCAD:

1. Put the calculator.dvb file in one of the AutoCAD search directories
2. Find the file acad.lsp
3. Open it
4A. If there is a STARTUP function
add the line:
Code:
    (command "_-vbaload" "calculator.dvb")
4B. If there is not a STARTUP function
add these lines to the .lsp file:
Code:
    (defun S::STARTUP()
        (command "_-vbaload" "calculator.dvb")
    )
Then, when AutoCAD starts, the calculator project will load. To run it, just run the macro in the list.

NOTE: If you don't have the file acad.lsp, that is fine too. Just create a new file and call it acad.lsp. Put this in one of the AutoCAD search directories. Then, add this code:
Code:
    (defun S::STARTUP()
        (command "_-vbaload" "calculator.dvb")
    )

Could you send me a copy of the project (.dvb) file?

If you are using AutoCAD 2000, I could also tell you how to make a custom button or menu to run the calculator program.

Hope this helps!
DimensionalSolutions@Core.com
While I welcome e-mail messages, please post all thread activity in these forums for the benefit of all members.
 
Thank you verry much this worked great i used the part u said to put into the acad.lsp file

(command "_-vbaload" "calculator.dvb")
put it infront of the macro i presently had and it loads great
thanks for all the help im presently working on takeing alll the lisp files i find on the web and making a custom menu file to load in autocad so if you just want the calculator im more than happy to give it to ya or if you like when im done with my menu file ill zip it up and let you have that as well and it includes the calculator
 
Shadow:

I would love to have the final package. In the meantime, if could you send me the calculator file, I would appreciate it. DimensionalSolutions@Core.com
While I welcome e-mail messages, please post all thread activity in these forums for the benefit of all members.
 
DSI and anyone else who reads this

I am currently working on a custom menu/lisp routines to add to autocad and if anyone has any suggestions ideas lisps custom osnap ideas that they would like to offer for a copy of the final product or part of it let me know

sherrin@shasta.com
 
I can provide some lisp routines of mine if anyone e-mails me. Example: I have a lisp routine which rotates a drawing to horizontal for plotting - useful for drawings with huge ref files attached and frames not horizontal.

I have another that joins lines into polilines without asking back - does it for each layer in succession, not mixing lines of different layers, and not touching lines on off layers.

Just ask for them and they are your.

Thanks

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor