Jump to content

Do an array by selecting a closed object.


Recommended Posts

Posted

Hi i'm looking to make an array in the zone of a certaine objet "polyline, rectangle"

 

i would like to know what function i would need to use to get to what i want.

 

thank for the help in advance!

 

Cheers and Beers !

Posted

Its pretty easy to select a object and create an array filling it using lisp, you need to also pick the control pt which controls the start of the array but you need also to pick a window covering the complete object so your control pt is moved correctly to say lower left, then a couple of choices erase all objects outside, trim to objects delete touching objects.

 

Post a image etc for more help.

 

find "Cookiecutter.lsp"

Posted

[ATTACH]32354[/ATTACH]

Post a image etc for more help.

 

Hi BIGAL,

 

the help would gladly be appreciated i will link a picture to help you out and the routine that goes with it

 

picture.jpg

 

here's the code :

 

;******************************************************              
;         ce sous program permet de créer un 
;                 cadre d'echafaudage
;******************************************************

(defun cadre()

  (setq pt1(getpoint"\nPointez premier point : "))
  (setq pt2(polar pt1 0 1220))
  (setq pt3(list(car pt2)(+(cadr pt1) 2135)))

  (command"_layer" "_n" "-LU CADRE" "_c" "5" "-LU CADRE" "")
  (command"_donut" "0" "150" pt1 "")
  (setq cir1(entlast))  
  (command"_donut" "0" "150" pt2 "")
  (setq cir2(entlast))
  (command"_pline" pt1 pt2 "")
  (setq lin1(entlast))
  
  (Command"_chprop" cir1 cir2 lin1 "" "la" "-LU CADRE" "")
  (command"_block" "lu blockt" pt1 cir1 cir2 lin1 "")
  (command"_insert" "lu blockt" pt1 "" "" "")
  (setq blockt(entlast))

)defun cadre

;******************************************************
;            début du program : échafaudage
;      ce program permet d'échafauder un projet     
;******************************************************

(defun c:ecf()
  
  (setq Obj-1(entsel "\nChoisir le Contour de la dalle : "))
  
  ;(constantes)
  ;(spécification)
  ;(calcul)
  (cadre)

  (command"_Pline" pt1 pt3 "") 
  (setq lin2(entlast))
  (command"_chprop" lin2 "" "la" "-LU CADRE" "")
  (Command"_array" blockt lin2 "" "r" "2" "2" "2135" "2440")
  
  
(princ)
  
);defun c:

 

Cheers & Beers!!

Posted

After looking at your drawing using array to fill is probably not the best method to use here its probably better to do a first principles and draw the scaffolding as objects maybe. I thought from your request you had lots of objects rather than a few.

Posted

Hi Bigal,

 

I do have alot of objets to put it but i'm trying to start from the beginning. those are only the frames. I also have beams to input and sometimes jacks. But an array might also not be the solution* as you say. I simply do not know what function i could use.

 

I also read about safearray but i not advanced enough to use those function.

 

I would only like to be pointed in the right derection.

 

Thanks alot for you time.

Posted

Its sounding like a program solution, you can still insert blocks same as an array but as you hint above get the program to work out spacing, search here for examples of grid programs to get an understand of multi creation of objects.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...