CAD Forums > BricsCAD Users

Help with Macro: Set Current Layer + Start LISP

(1/2) > >>

CEHill:

GOAL: Create a button macro that combines two actions.

Actions include:

1.) Set a layer (named Fastener) as current and

2.) Invokes an AutoLISP program that allows the user to select and insert a fastener. 

I have a basic understanding of button macro code. I am unsure of how to combine the two steps into one macro.

Thanks,
Clint

JohnK:
How would you do this "normally" (-i.e. macros, are made by just writing down the steps [commands] you'd type to accomplish a task)?

1. Type: "-la"
2. Type: "set"
3. Type: "Fastner"
4. Type: <ENTER>
5. Type: "-i"
...

CEHill:
Of course.

So, the portion of the code that invokes the LISP part of the code would be ^C^C(C:FAST)  ???


C.

JohnK:
^c^c means: cancel, cancel (or escape, escape).

(c:fast) means what?

CEHill:
This code is an attempt to start the AutoLISP file, FAST.lsp, that was available years ago on the CADALYST website.

As supplied, the FAST.lsp code does not include code to create/set a specific layer.

To ensure that the output of the FAST.lsp is placed on the desired layer, I would like to create a button macro that

1.) Sets the FASTENER layer as current and

2.) Runs the FAST.lsp program.

The code successfully sets the FASTENER layer as current.

It does not invoke the AutoLISP program, FAST.lsp.

I need help with the AutoLISP portion below.


--- Code - Auto/Visual Lisp: ---^C^C^C-Layer;S;FASTENER;;(C:FAST)

Navigation

[0] Message Index

[#] Next page

Go to full version