Leaderboard
Popular Content
Showing content with the highest reputation on 05/13/2020 in all areas
-
hi please be patient , this post is nothing related to this topic: sum-of-attribute-values at all1 point
-
Had another go a simpler method using Autocads pedit multiple. (defun c:fbl3 ( / fr pt1 pt2 ss) (setq fr (getvar 'filletrad)) (initget 6) (setq rad (cond ( (getreal (strcat "\nEnter Fillet Radius <" (rtos fr) "> : "))) (fr))) (if (/= rad fr) (setvar 'filletrad rad)) (setq pt1 (getpoint "\nPick 1st cnr point")) (setq pt2 (getpoint pt1 "\nPick 1st cnr point")) (command "Pedit" "m" "w" pt1 pt2 "" "Y" "Join" 0.0 "") (setq ss (ssget "w" pt1 pt2 '((0 . "LWPOLYLINE")))) (repeat (setq x (sslength ss)) (setq ent (ssname ss (setq x (- x 1)))) (setq pt1 (vlax-curve-getendpoint (vlax-ename->vla-object ent))) (command "fillet" "P" pt1 ) ) (princ) ) (c:fbl3)1 point
-
Welcome to CADTutor Astripes. This is so monumentally simple. In summation of everything that was posted before. A couple years late to the party but after tweaking one's Polar Settings as shown in the image, and devoting less than five minutes (likely a lot less) test driving this configuration I should think most users would be good to go, back on the tracks, and getting back to social distancing and work. Yes, there are those who favor using the Dynamic Input, with two fields, one for angle, and the other for distance, personal preference, and good functionality. I don't think this will constitute news to all those forum members who were trying to help the OP. I am reminded of the old Abbot & Costello riff "Who's on first?" I wouldn't have posted to this old thread, except that Astripes posted a follow up question.1 point
-
This topic has been asked and discussed for at least ten years, and is still asked today among new Revit users in the community and the answer has always been and always will be - it does not work. So your assumptions are correct. You do have options, and Remote Desktop to a local machine on the network isn't a great or ideal workflow either. The only two viable options are this: You can purchase a BIM 360 license and use Autodesk's cloud service, or you can have your I.T. department set up Revit Server. Without a doubt, BIM 360 is the easiest and overall cheapest (all things considered) option for those who use Revit on a consistent and frequent basis. BIM 360 works so well, that by all reasonable accounts, it's the only option available. It provides a 99.9% uptime rate, unlimited backup storage, user permissions and access to other tools that make your Revit world much easier. In short, it's very much worth it. https://www.autodesk.com/bim-360/bim-collaboration-software/design-collaboration/revit-cloud-worksharing/ I've been using it since its inception back in 2015 and I have never looked back and couldn't imagine not using it. It also handles the Central and Local files automatically so no more "create local copies" and outdated sync issues, etc. I would immediately suspend the use of any cloud based file syncing application. -TZ1 point
-
In AutoCAD you could start by saving the value of PLINEWID (setq PLINEWID (getvar "PLINEWID")) then after drawing the polyline finish by resetting it to what it was before. (setvar "PLINEWID" PLINEWID) Not familiar with nanocad it may work the same way.1 point
-
Technically I'm only using the end points of the IFC drawings, which explain why it didn't capture some of the points whose end point is residing on the As-Builts. I didn't knew you want it that way. P.S. you're not the only one around here who's free of time you know. I have my own duties to carry as well! (defun c:survey ( / *error* acadobj activeundo adoc all dets esclays i instpt lay1 lay2 layers ln msp pointheight rtn ss tolerance totable txthgt vtab) (defun *error* ( msg ) (vla-EndUndoMark adoc) (if (not (wcmatch (strcase msg T) "*break*,*cancel*,*exit*")) (princ (strcat "Error: " msg)) ) ) (setq acadobj (vlax-get-acad-object) adoc (vla-get-ActiveDocument acadobj) msp (vla-get-ModelSpace adoc) activeundo nil) (if (= 0 (logand 8 (getvar "UNDOCTL"))) (vla-StartUndoMark adoc) (setq activeundo T)) (setq ;; ------------------------------------------ SETUPS ------------------------------------------ ;; layers '("IFC" "As-Built") ; <--- a list of two strings (texts) representing the layer of the texts ; ^^^ the first layer will be compared to the second. pointheight 400 ; <--- the text height for the labels on the drawing tolerance 200 ; <--- the tolerance (how far apart should the points be to still be considered equal) ;; Table generated will only look based on screen size, so irrespective of zoom ;; ------------------------------------------ SETUPS ------------------------------------------ ;; esclays (mapcar '(lambda (x) (cons 8 (LM:escapewildcards x))) layers) ) (if (and (setq ss (ssget (append '((0 . "LINE") (-4 . "<OR")) esclays '((-4 . "OR>"))))) (foreach x (setq ln (JH:selset-to-list ss)) (if (eq (strcase (cdr (assoc 8 (entget x)))) (strcase (car layers))) (setq lay1 (cons (list (vlax-curve-getStartPoint x) (vlax-curve-getEndPoint x)) lay1)) (setq lay2 (cons (list (vlax-curve-getStartPoint x) (vlax-curve-getEndPoint x)) lay2)) ) ) (setq all (LM:UniqueFuzz (append (apply 'append lay1) (apply 'append lay2)) 1e-4)) (progn (foreach x all (vl-some '(lambda (y / cl) (if (and (equal x (setq cl (vlax-curve-getClosestPointTo y x)) tolerance) (null (equal x cl 1e-4)) ) (setq rtn (cons (list x cl) rtn)) ) ) ln ) ) rtn ) (setq instpt (getpoint "\nSpecify insertion point for table: ")) ) (progn (setq i 0 txthgt (* 0.011 (getvar 'viewsize)) dets (mapcar '(lambda (x / vt) (vla-put-Alignment (setq vt (vla-AddText msp (itoa (setq i (1+ i))) (vlax-3d-point 0 0 0) pointheight)) acAlignmentTopLeft ) (vla-put-TextAlignmentPoint vt (vlax-3d-point (car x))) (list (itoa i) (rtos (cadar x) 2 3) (rtos (caar x) 2 3) (rtos (cadr (last x)) 2 3) (rtos (car (last x)) 2 3) (rtos (apply '- (mapcar 'cadr x)) 2 0) (rtos (apply '- (mapcar 'car x)) 2 0) (rtos (apply 'distance x) 2 0) "OUT" ) ) rtn ) totable (cons '("" "DESIGN" "" "AS-BUILT" "" "DIFFERENCE" "" "" "DISCR") (cons '("S No." "NORTHING" "EASTING" "NORTHING" "EASTING" "DIF N" "DIF E" "DIF DIST" "") dets) ) vtab (vla-AddTable msp (vlax-3d-point instpt) (+ 2 (length dets)) 9 (* 2 txthgt) (* 15 txthgt)) ) (vla-put-RegenerateTableSuppressed vtab :vlax-true) (vla-UnmergeCells vtab 0 (1+ (length dets)) 0 8) (foreach x '( (0 0 1 2) (0 0 3 4) (0 0 5 7) (0 1 8 8) ) (apply 'vla-MergeCells (append (list vtab) x)) ) (vla-put-RegenerateTableSuppressed (JH:put-list-to-table vtab totable 0 0 txthgt) :vlax-false) ) ) (if activeundo nil (vla-EndUndoMark adoc)) (princ) ) ;; JH:selset-to-list --> Jonathan Handojo ;; Returns a list of entities from a selection set ;; ss - selection set (defun JH:selset-to-list (selset / lst iter) (if selset (repeat (setq iter (sslength selset)) (setq lst (cons (ssname selset (setq iter (1- iter))) lst)) ) ) ) ;; JH:put-list-to-table --> Jonathan Handojo ;; Attempts to put a list of texts into a table. ;; vtab - table VLA object ;; lst - a list where each item is another list of strings to be put into the table ;; row - the first (upper) row where the list will be inserted (zero-based index) ;; col - the first (left) column where the list will be inserted (zero-based index) ;; hgt - text height on table (nil to ignore) (defun JH:put-list-to-table (vtab lst row col hgt / activesuppressed i j) (if (eq (vla-get-RegenerateTableSuppressed vtab) :vlax-true) (setq activesuppressed T) (vla-put-RegenerateTableSuppressed vtab :vlax-true) ) (setq i 0) (foreach x lst (setq j -1) (foreach y x (vl-catch-all-apply 'vla-SetText (list vtab (+ row i) (+ col (setq j (1+ j))) y)) (if hgt (vl-catch-all-apply 'vla-SetCellTextHeight (list vtab (+ row i) (+ row j) hgt)) ) ) (setq i (1+ i)) ) (if (null activesuppressed) (vla-put-RegenerateTableSuppressed vtab :vlax-false)) vtab ) ;;; -------------------------------- ONLINE REFERENCES -------------------------------- ;;; ;; Escape Wildcards - Lee Mac ;; Escapes wildcard special characters in a supplied string (defun LM:escapewildcards ( str ) (vl-list->string (apply 'append (mapcar '(lambda ( c ) (if (member c '(35 64 46 42 63 126 91 93 45 44)) (list 96 c) (list c) ) ) (vl-string->list str) ) ) ) ) ;; Unique with Fuzz - Lee Mac ;; Returns a list with all elements considered duplicate to ;; a given tolerance removed. (defun LM:UniqueFuzz ( l f / x r ) (while l (setq x (car l) l (vl-remove-if (function (lambda ( y ) (equal x y f))) (cdr l)) r (cons x r) ) ) (reverse r) ) Some areas that you clouded don't even have end points. How the hell is it supposed to find those then?1 point
-
@Temy Tested and working. I think it covers every case so far. It utilises the dynamic prompt for the All/Select prompt default is All so a right click or enter will select the default. Default for fillet radius is the current fillet radius as before. (defun c:fbl ( / *error* c_doc sv_lst sv_vals fr fuzz typ rad filter ss ssp bx cnt ent lyr) (vl-load-com) (defun *error* ( msg ) (if (and c_doc (= 8 (logand 8 (getvar 'UNDOCTL)))) (vla-endundomark c_doc)) (mapcar 'setvar sv_lst sv_vals) (if (not (wcmatch (strcase msg) "*BREAK*,*CANCEL*,*EXIT*")) (princ (strcat "\nOops an Error : " msg " occurred."))) (princ) );_end_*error*_defun (setq c_doc (vla-get-activedocument (vlax-get-acad-object)) sv_lst (list 'cmdecho 'osmode 'peditaccept 'dynmode 'dynprompt 'filletrad) sv_vals (mapcar 'getvar sv_lst) fr (getvar 'filletrad) fuzz 1.0e-6 );end_setq (mapcar 'setvar sv_lst '(0 0 1 3 1)) (initget "All Select") (setq typ (cond ( (getkword "\nProcess All or Selected Layers? : [All/Select] <All>")) ("All"))) (if (= typ "Select") (setq ent (car (entsel "\nSelect Object on layer to fillet : ")) lyr (cdr (assoc 8 (entget ent))))) (initget 6) (setq rad (cond ( (getreal (strcat "\nEnter Fillet Radius <" (rtos fr) "> : "))) (fr))) (if (/= rad fr) (setvar 'filletrad rad)) (if (and c_doc (= 8 (logand 8 (getvar 'UNDOCTL)))) (vla-endundomark c_doc)) (vla-startundomark c_doc) (if (= typ "Select") (setq filter (list '(0 . "LINE") (cons 8 lyr))) (setq filter (list '(0 . "LINE")))) (setq ss (ssget ":L" filter)) (cond (ss (command "_.pedit" "_M" ss "" "_J" fuzz "") (setq bx (mapcar 'cdr (apply 'append (mapcar 'cdr (vl-remove-if-not '(lambda (x) (minusp (car x))) (ssnamex ss))))) ssp (ssget "_WP" (apply 'append bx) '((0 . "LWPOLYLINE"))) ss nil );end_setq (repeat (setq cnt (sslength ssp)) (setq ent (ssname ssp (setq cnt (1- cnt)))) (command "fillet" "_P" ent) (command "explode" ent) );end_repeat ) );end_cond (if (and c_doc (= 8 (logand 8 (getvar 'UNDOCTL)))) (vla-endundomark c_doc)) (mapcar 'setvar sv_lst sv_vals) (princ) );end_defun Any problems let me know1 point
-
1 point