Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/06/2020 in all areas

  1. If you're familiar with using VLA methods, you can access another drawing yes. You use vla-get-ActiveDocument to get the vla-object of your active document... you can use the below (a snippet of the Steal Routine by Lee Mac) to get the vla object the document of another drawing. (defun steal:getdocumentobject ( filename / acdocs dbdoc vers ) (vlax-map-collection (vla-get-documents (vlax-get-acad-object)) (function (lambda ( doc ) (setq acdocs (cons (cons (strcase (vla-get-fullname doc)) doc) acdocs)) ) ) ) (cond ( (null (setq filename (findfile filename))) nil ) ( (cdr (assoc (strcase filename) acdocs)) ) ( (null (vl-catch-all-error-p (vl-catch-all-apply 'vla-open (list (setq dbdoc (vla-getinterfaceobject (vlax-get-acad-object) (if (< (setq vers (atoi (getvar 'acadver))) 16) "ObjectDBX.AxDbDocument" (strcat "ObjectDBX.AxDbDocument." (itoa vers)) ) ) ) filename ) ) ) ) dbdoc ) ) ) So you can perform something like: (foreach x '(your_list_of_dwg_paths) (setq dbdc (steal:getdocumentobject x)) ;; and do your stuff here (vlax-release-object dbdc) )
    1 point
  2. While doing some more searches, I found this. Need time to understand what it's doing but looks pretty good for down and dirty detail work. https://www.blocklayer.com/stairs/spiral-stairseng.aspx
    1 point
  3. You should have access to the AutoCAD Architectural Toolset, it does spiral stairs and rails. It took me only a few hours to figure out how to make a custom rail into a 4 board fence, so customization seems easy. I just did a few simple spiral stairs, seems simple enough. If needed in Autocad you'll need to Convert to 3D Solids.
    1 point
  4. Almost there did not get the bottom angle trim quite right. (setq angdiff (/ (- 169.9437000 135.0000000) 12.0)) (setq ang1 135.0) (setq ip (getpoint "Pick centre")) (setq h2 6.0) (repeat 12 (setq ip (list (car ip) (cadr ip) (+ (caddr ip) h2))) (command "insert" "aaa" ip "" "" ang1) (setq ang1(+ ang1 angdiff)) )
    1 point
  5. Way back in 1990 did a 3d spiral stair lisp it was a repeat of a single tread including handrail copy vertical and rotated. It was instant done as a sales tool. Any way back to your stair need to add the under side concrete that is what holds them up. Re bottom holds them up "Enzed" stairs are self supporting the treads are oversize each bolted to next so stairs float. Again 1990. Maybe even add the bottom to your tread then copy and rotate. The tread has a taper inside rad to outside rad. so extrude the shape with correct taper or slice off a over size shape to get taper and curved ends.
    1 point
  6. And here is very simple example of how to process list of number strings... ;;;--------------------------------------------------------------------------------------------------------------;;; ;;; multplst - sub function - successive multiplication numbers of any length stored in a list of number strings ;;; ;;; ;;; ;;; Requirements : Loaded (multp a b) sub-function ;;; ;;; ;;; ;;; Arguments : ;;; ;;; lst - list of number strings - type = list ; for ex. (setq lst '("2" "4" "6")) ;;; ;;; ;;; ;;; Return : ;;; ;;; r - resulting number - type = string ;;; ;;; ;;; ;;; AutoLisp synonym : ;;; ;;; (apply (function *) lst) => number (real or integer) ; lst - list of numbers (reals or integers) ;;; ;;; ;;; ;;; Example : ;;; ;;; (setq lst '("2" "4" "6")) ;;; ;;; (setq r (multplst lst)) => r = "48" ;;; ;;; (princ (strcat "\n" r)) => 48 ;;; ;;; (princ) ;;; ;;; ;;; ;;; Written by Marko Ribar, d.i.a. (architect) ;;; ;;;--------------------------------------------------------------------------------------------------------------;;; (defun multplst ( lst / r ) (setq r "1") (while (car lst) (setq r (multp r (car lst))) (setq lst (cdr lst)) ) r ) P.S. You have to have loaded (multp a b) sub-function I posted in my previous code... HTH. Regards, M.R.
    1 point
×
×
  • Create New...