Search the Community
Showing results for tags 'autocad'.
-
block insertion point and Block attribute value
Kubucama posted a topic in AutoLISP, Visual LISP & DCL
Hello everyone, The attached code that "Replace the text by block and transfer the value to the attribute" and the code is working. What I intend to do now and am not succeeding in doing is the following : 1) I noticed that, the block insertion point is being at the coordinate (Geometry --> Position X of variable T2B_Text). Is it possible to insert the block at the coordinate ( Text --> Text alignment X of variable T2B_Text)? (See image 1) 2) Is there any way to make sure that the total value of the variable "T2B_AttributeTag" is not all transferred to the block attribute? (See image 2) Example: T2B_AttributeTag = TO 1301-UZY-1826A Value of Block attribute (T2B_Block) = 1301-UZY-1826A (Accurate this way) Obs : The Txt file is by (DannyNL), taken from the AutoCad forum. Code Lisp.txt -
autocad architecture Projecting generated sections to lines
Bojan posted a topic in Architecture & ADT
Hello fellow Autocad users, I've recently recieved a messy 3d model (consisting of various geometry types) in order to draw section plans from them. First I tried to generate a floorplan with Autocads "Generate Section/Elevation" tool, thus recieving the projection as intelligent object. In order to draw the plans cleanly from the messy projection I want to transform the projection into a linegrafic, but I can't find a way to edit the projections without crashing Autocad. I also can't use flatshot since the projection is not a Brep. Is there any way to transform the projection into a line grafik, or another alternative to generate cross sections? I've attached an image to depict the problem (I use a german version of AutoCad architecture 2020). Thank you in advance! -
Electric Transmission poles
Shablab posted a topic in AutoCAD 2D Drafting, Object Properties & Interface
Are there any resources I can take a look at to find all different types of electric transmission poles in autocad. -
Can anyone help me for the create lisp for following condition . * I have 200 of text separately in my drawing ..i want block them individually each one. *i want select 200 of text at once block them individually .. Can any one create lisp for that.thank
-
Hi, I'm having a hard time figuring out how to make a toolbar that can be downloaded for all to use. My problem is how do you share a "common directory" with the world? The toolbar works perfectly fine on my computer, because I have defined my own directory in the macro under the cui command. So the question is: how do you make a "common directory" so that the toolbar can be accessed on any computer? I hope I have made myself clear. Thanks!
- 13 replies
-
- custom toolbar
- cui
- (and 9 more)
-
I have a problem with trim command. When im in the trim command, window selection doesn't work. Only crossing window. I've been trying everything that i can like PICKFIRST, PICKDRAG etc. I searched it online but there is no solution. :(
-
Not sure what i have been missing here. But finally decided to do something about our custom code. The lisp looks for a file and if present on system proceeds to step 2. Step 2 it checks for match with path. this is where i get confused.. I thought a (princ) close's the file clean (no loose ends) however the settings are there (in the options) but not applied. what am I missing? I have looked for some way to apply settings under the options dialog but no success. (Setvar "cmdecho" 0) (if (= "24.0s (LMS Tech)" (getvar "ACADVER")) (progn (if (not (wcmatch (getenv "PrinterConfigDir") "*path*")) ;Looking for Printer Configuration Search Path (setenv "PrinterConfigDir" "path") ;If not found add Printer Configuration Search Path ) (if (not (wcmatch (getenv "PrinterDescDir") "*path*")) (setenv "PrinterDescDir" "path") ;If not found add Printer Description Search Path ) (if (not (wcmatch (getenv "PrinterStyleSheetDir") "*path*")) ;Looking for Path in Plot Style Table Search Path (setenv "PrinterStyleSheetDir" "path;") ;If not found add Plot Style Table Search Path ) ) ) ;(alert "message") (Setvar "cmdecho" 1) (princ)
-
I can convert my raw AutoLISP (.lsp) codes into Visual Lisp (.VLX) and .FAS application using AutoCAD VLISP IDE. I was looking into Autodesk App Store and downloaded some of the free applications. It was .msi. That means it will install directly on Windows and link-up with installed AutoCAD. I am very new in the App Store. Could you please help me to understand to convert my .lsp or .vlx or .fas into .msi? Thanks.
- 4 replies
-
- autolisp
- visual lisp
-
(and 3 more)
Tagged with:
-
Hi all, does anyone know how it is possible to be a tester of beta (and alpha) versions of AutoCAD and Revit and other Autodesk products? I appreciate any help!
-
Hi All, anyone knows when AutoCAD 2021 will be available?
-
Where can I send wishlist to Autodesk?
Ahankhah posted a topic in AutoCAD Bugs, Error Messages & Quirks
Hello everybobdy, is it possible to let me know how I can send Autodesk my wishlist about AutoCAD and Revit and other Autodesk packages? I appreciate any help! -
Run overkill command or similar on current layer only
david1-b posted a topic in AutoLISP, Visual LISP & DCL
Hello, I have been working on a VLISP routine that reads from a txt file and draws some plines based on the text file. As a result of how the text files are received some lines are drawn as duplicates. Accordingly, I would like to run the overkill command or something similar at the end of the routine on only the active layer. Can anyone provide advice or code snippets as to how I can complete this. I did not see an ActiveX reference to OVERKILL, and am pretty new to vlisp (so go easy). Thanks David -
Hi, i was searching for some good block for free and I found this website, i would like to share with you. It has over 200 blocks well organized by category (indoors, outdoors, vehicles, people, office etc.) and above all they are free and with no need of registration. There's also some pattern. They also have a 3ds max section but i think it's under construction Hope it helps http://max-cad.com
-
how to do the automatically offset in between two lines offset centerline for all
amarendra posted a topic in AutoLISP, Visual LISP & DCL
Hello Dear Friends, how to do the automatically offset in between two lines offset centerline for all. kindly find the attached for sample image with drawing. if anyone knows lisp please help me. I am using AutoCAD 2017 Thanks Amarendra HVAC sample Offset.dwg -
Hello Everyone, I'm working on a GIS Application which is running with AutoCAD, in that we are placing some lines and structures, while placing that the annotation will be placced automatically middle point of that poly line. after that we need to align that as per the below image. is there any possible to align the blocks automatically. steps would be Select two Blocks--->Select the Line then the blocks should be alined automatically as per the below image. can anyone help me on this. Thanks in advance. Sample.dwg
-
Hi guys, I have 3d polyline net system as you can see down below, trying to measure every cell automatically (see attachment), problem is that net is 3 dimensional and hard to define measuring angular, every 3d polyline is individual (see attachment) just want to select the 3d polyline and giving measures between nodes, do anyone know how to solve this puzzle an easiest way? Best Regards
-
Hello, I am interested in a LISP able to make overlapping sheets as layouts following a road alignment and overlap a fraction. Each sheet will have its own UCS or view orientation. You can see it from these videos: anyone knows one? Best regards, Daniel
-
I currently have a lisp routine to place a block at intersection points with one main line (RED) and then all other lines (WHITE) that cross it. I have a problem and cant seem to figure out how to adjust the code to make it work more fluid. I would like the main line to be able to be crossed more than once by a different line and still work. Currently if a RED line is crossed twice by any single white line it will not work and the lisp will bottom out and end (vl-load-com) (defun c:sbx ( / ) (progn (setq ent (car (entsel "\nSelect main line: "))) (if ent (progn (princ "\nSelect crossing line(s): ") (if (setq ss (ssget)) (progn (setq count 0 obj (vlax-ename->vla-object ent) pointlist nil ) (repeat (sslength ss) (setq xent (ssname ss count) xobj (vlax-ename->vla-object xent) ) (if (setq int (vla-IntersectWith obj xobj acExtendNone)) (progn (setq int (vlax-safearray->list (vlax-variant-value int)) pointlist (append pointlist (list int)) ) ) ) (setq count (1+ count)) ) (if (null (tblobjname "BLOCK" "SBblock")) (progn (entmake (list (cons 0 "BLOCK") (cons 2 "SBblock") (cons 70 0) (list 10 0.0 0.0 0.0))) (entmake '((0 . "LWPOLYLINE") (100 . "AcDbEntity") (8 . "0") (100 . "AcDbPolyline") (90 . 2) (70 . 1) (43 . 1.0) (38 . 0.0) (39 . 0.0) (10 2.5 0.0) (40 . 1.0) (41 . 1.0) (42 . 1.0) (91 . 0) (10 -2.5 0.0) (40 . 1.0) (41 . 1.0) (42 . 1.0) (91 . 0) (210 0.0 0.0 1.0) ) ) (setq blockname (entmake '((0 . "ENDBLK")))) ) ) (foreach pt_nth pointlist (entmake (append '((0 . "INSERT") (100 . "AcDbEntity") (8 . "0") (100 . "AcDbBlockReference") (2 . "SBblock")) (list (cons 10 pt_nth)) '((41 . 1.0) (42 . 1.0) (43 . 1.0) (50 . 0.0) (70 . 0) (71 . 0) (44 . 0.0) (45 . 0.0) (210 0.0 0.0 1.0)) ) ) ) ) ) ) ) ) (princ) )
-
How to use reference parameters usefully?
SamiHawasli posted a topic in AutoCAD 2D Drafting, Object Properties & Interface
Hello all, I am creating a parametric drawing and I've run across a problem. AutoCad lets you define reference parameters, a measurement from a driven object, but when i try to use those reference parameters in a function, I get an error. I'm not even using the reference parameter to drive another object, simply to calculate some ratio. Perhaps my syntax is wrong, or its just impossible to use a reference parameter in such a way? Any help would be much appreciated, Sami -
Basically, I want to select two objects, and have them displaced the same amount in opposite directions from a set point without having to do the offset command in the case that the distance may be an odd or unknown value. To summarize, I have two polylines and want to offset them away from eachother using either a typed in distance or a "point-to-point" distance like the current offset command.
-
I have a line that crosses through multiple polygons. Is there a LISP to give me a count of how many polygons this line goes through?
-
Hello Please I need help with my very very old lsp program. It has been made with my colleague in around 1998-1999. Now after a long time we need to edit it to add new block tags and make it count block we specify. We have been working on it almost a week but we really dont have a clue how to edit program after that time. I am asking for a help from some good programmer to help us solve this. All help is appreciated. Lisp file content: (defun f1 () (setq pocs 1) (pp) (if (/= aaa "") (f1a) (setq pocs 0))) (defun f1a () (setq pol (assoc aaa sez)) (if (= pol nil) (f1a2) (f1a1))) (defun f1a1 () (setq cis (cdr pol)) (setq cis (+ pocs cis)) (setq pom (cons aaa cis)) (setq sez (subst pom pol sez))) (defun f1a2 () (setq sez (cons (cons aaa pocs) sez)) (setq nav nil)) (defun f2 () (setq poc (length sez)) (if (> poc 0) (fl)) (while (> poc 0) (setq prv (nth (- poc 1) sez)) (setq zna (car prv)) (setq ccc (cdr prv)) (setq spc (- 16 (strlen zna))) (setq zna (strcat zna (substr " " 1 spc) (itoa ccc))) (write-line zna s2) (write-line zna) (setq poc (- poc 1)))) (defun f3 () (setq pocs 0) (pp) (if (/= aaa "") (f3a))) (defun f3a () (setq pocs 1 pozn (strlen aaa)) (if (= pozn 1) (f1a) (f3b))) (defun f3b () (setq pzn (substr aaa 1 1)) (if (and (>= pzn "0") (<= pzn "9")) (f4a) (f6)) (f1a)) (defun f4a () (fc) (setq pzn (substr aaa 1 1)) (if (>= pzn "A") (setq pocs ccc) (f5))) (defun f5 () (setq aaa (substr aaa 2) pzn (substr aaa 1 1)) (if (>= pzn "A") (setq aaa pzn) (f6))) (defun f6 () (fd) (setq pzn (substr aaa 1 1)) (if (and (>= pzn "0") (<= pzn "9")) (f7) (setq aaa pzn))) (defun f7 () (fc) (setq aaa (substr aaa 1 1) pocs ccc)) (defun fd () (setq pzn "x") (while (and (/= pzn "(") (> pzn "")) (setq pzn (substr aaa 1 1)) (setq aaa (substr aaa 2)))) (defun fc () (setq zn "0" bbb "") (while (and (>= zn "0") (<= zn "9")) (setq bbb (strcat bbb (substr aaa 1 1))) (setq aaa (substr aaa 2)) (setq zn (substr aaa 1 1))) (setq ccc (atoi bbb))) (defun fl () (write-line nadpis) (write-line nadpis s2)) (defun fp () (setq inp (open vyso "r")) (setq out (open "lpt1" "w")) (setq q (read-line inp)) (while (/= q nil) (write-line q out) (setq q (read-line inp))) (write-line " " out) (close inp) (close out)) (defun pp () (setq n 0 zn nil) (while (/= zn " ") (setq n (+ 1 n)) (setq zn (substr aaa n 1))) (setq pzn (- n 1)) (setq aaa (substr aaa 1 pzn))) (defun f8 () (setq nadpis "***** Svitidla dle symbolu *****") (setq sez sez6) (f2)) (defun c:vypis () (textscr) (command "attext" "s" "c:/blok/vypis/material" "c:/blok/vypis/pracovni") (setq pre (getvar "dwgprefix") nam (getvar "dwgname")) (setq n (strlen nam) nn 0) (while (> n 1) (setq zn (substr nam n 1)) (if (= zn "\\") (setq nn n n 2)) (setq n (- n 1))) (setq nam (substr nam (+ nn 1))) (setq zxc (strcat pre nam ".PRN")) (princ (strcat "\nJmeno vysledneho souboru <" zxc ">\n")) (setq vyso (getstring)) (if (= vyso "") (setq vyso zxc)) (write-line " ") (setq sez1 () sez2 () sez3 () sez4 () sez5 () sez9 () sez6 () c3 0 c6 0) (setq sou (open "c:/blok/vypis/pracovni.txt" "r")) (setq rad (read-line sou)) (while (/= rad nil) (setq sez sez1) (setq aaa (substr rad 1 15)) (f1) (setq sez1 sez sez sez2) (setq aaa (substr rad 16 15)) (f1) (setq sez2 sez sez sez3) (setq aaa (substr rad 31 15)) (f3) (setq c3 (+ c3 pocs)) (setq sez3 sez sez sez4) (setq aaa (substr rad 46 15)) (f1) (setq sez4 sez sez sez5) (setq aaa (substr rad 61 15)) (f1) (setq sez9 sez sez sez9) (setq aaa (substr rad 76 15)) (f1) (setq sez5 sez sez sez6) (setq aaa (substr rad 91 15)) (f1) (setq c6 (+ c6 pocs)) (setq sez6 sez) (setq rad (read-line sou))) (close sou) (setq s2 (open vyso "w")) (setq nadpis (strcat " Vykres: " nam)) (fl) (setq nadpis "--------------Zasuvky-------------") (setq sez sez1) (f2) (setq nadpis "--------------Spinace-------------") (setq sez sez2) (f2) (setq nadpis "--------Svitidla dle popisu-------") (setq sez sez3) (f2) (setq nadpis "--------------Ostatni-------------") (setq sez sez4) (f2) (setq nadpis "--------------Ostatni-------------") (setq sez sez9) (f2) (setq nadpis "----------Ulozeni vedeni----------") (setq sez sez5) (f2) (if (/= c3 c6) (f8)) (setq nadpis "----------------------------------") (fl) (close s2) (write-line "Vytisknout na tiskarne? (A/N)") (setq ano (grread)) (if (or (equal ano '(2 65)) (equal ano '(2 97))) (fp)) (read (chr (car (cdr ano))))) Then lisp have two templates 1.material zas c01500 spin c01500 svi c01500 ost c01500 rost c01500 sve c01500 test c01500 2.pracovni ST Z24V V3 V3S VV5 VV766 TOV66 VV666 VV566 VV166 ZV1 TOV VV7 VV6 V644 VV1 Z144 TO44 V744 V544 V144 V2 V7 Z1 TOS TO V1S V51 V66 V6 V5 V1 VYN KR pc ve p boiler N2 VY V SS1 SN SN1 SS Z2 ZST ZSTA DT VYM Z3 Z1P servo SC os iz HOP zem_svorka STM vz Z1v RauchAlarm Z2p ochranaT3 ochranaT3 ochranaT3 tr nap EP1 EP2 V5144 V6644 SSm klim PKZ ZMn VYMN Zm Stlak STH pc44 258 458 158 436 236 149 128 139 124 224 pasLED LEDp LED LEDm S4 S6 S5 vz44 Tx Rx S12 S13 S21 S22 S31 S32 900 120 150 Vm Scm Scs Scv Skm Sks Skv Nkm Ncm 150 60 90 120 Zvv66 V6S VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV6 VV1 VV6 VV6 VV6 VV6 VV1 S12 S12 S12 S12 S12 S12 VV6 VV6 ZV1 ZV1 ZV1 ZV1 ZV1 ZV1 ZV1 ZV1 V3S Z1 TO V1S V1 pc p boiler Z2 Z2p VYMN V6S ochranaT3 WSB4 All files in attachment. VYPIS.LSP material.txt pracovni.txt
-
Hi Everyone, We are having 25+ draftsmen in our company and we like to have software to track the time spend on the drawings. We use AutoCAD, Inventor, Solidworks and Revit. I saw many software but nothing is as expected. Does anyone suggest software for that? Also please let me know if there is any free or trial version to test before we buy it. Thanks
- 2 replies
-
- autocad
- time tracker
- (and 4 more)
-
Hello everyone, I'm in a trouble, im making my thesis plans in autocad 2012 version and i need to rescale my plans from 1:1 to 1:100 and 1:300. Thanks for your respond and help.
- 2 replies
-
- architecture
- drawing scales
-
(and 1 more)
Tagged with:
-
Hello. I am a student and I need your help. My task is to write a program in AutoLISP that draws parts but I have no idea how to do it. The program in the simplest version which is only possible - I know that for some of you it's a bit of a job, so if it was possible, I would ask for help. I will try to repay somehow . Greetings. Sorry for my English.