• This forum is the machine-generated translation of www.cad3d.it/forum1 - the Italian design community. Several terms are not translated correctly.

block entry command

  • Thread starter Thread starter joe
  • Start date Start date

joe

Guest
Good morning, my intention is to create, in a custom menu, a command that inserts me into the design a type of block I always use. of course on the menu item, the command should allow me to directly insert the block, asking me only the insertion point.
is it possible to achieve this quickly with a lisp?
Thank you.
 
(command "_insert" nameblock entry point scalax scalay rotation)

nameblock: without path if file present in the search paths of autocad
insertion point: you can use (getpoint "\npoint insert: ") or pass the coordinate
scalax: value or breaks to insert value during insertion
scalay: value or breaks to insert value during insertion
rotation: value in degrees or breaks to insert value during insertion

(command "_insert" nameblock "_scale" scale breaks)
view the block when entering scale and asks point and rotation
 
Please, since the lisp doesn't work, I think it can depend on brackets or empty spaces.
You could write it to me. the file is prisoner.dwg and is located in a search path
Thank you.
 
(command "_insert" "prisoner.dwg" (getpoint "\n insertion point: ") 1 1 breaks)
or
(command "_insert" "prisoner.dwg" "_scale" 1 breaks)
 
Thank you.
but instead of doing a lsp file, can you enter this routine directly into the "he" by associating it with a new command?
 
I created a new command in the "he" file and inserted this: -inser "vita 2d.dwg"
at this point the block I can insert it into any point, but I would like to avoid manually inserting the scale and rotation into the command line and then closing the command once the insert point is fixed.
What should I add to that line?
 
I created a new command in the "he" file and inserted this: -inser "vita 2d.dwg"
at this point the block I can insert it into any point, but I would like to avoid manually inserting the scale and rotation into the command line and then closing the command once the insert point is fixed.
What should I add to that line?
-inser "vites 2d.dwg" \1 1 0;
this should be the syntax (memory vade...) to insert the block into a point required to the user in x and y = 1 scale and rotation angle 0.[/B]
 

Forum statistics

Threads
44,997
Messages
339,767
Members
4
Latest member
ibt

Members online

No members online now.
ciao
Back
Top