Jump to content

Search the Community

Showing results for tags 'autolisp'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • CADTutor
    • News, Announcements & FAQ
    • Feedback
  • AutoCAD
    • AutoCAD Beginners' Area
    • AutoCAD 2D Drafting, Object Properties & Interface
    • AutoCAD Drawing Management & Output
    • AutoCAD 3D Modelling & Rendering
    • AutoCAD Vertical Products
    • AutoCAD LT
    • CAD Management
    • AutoCAD Bugs, Error Messages & Quirks
    • AutoCAD General
    • AutoCAD Blogs
  • AutoCAD Customization
    • The CUI, Hatches, Linetypes, Scripts & Macros
    • AutoLISP, Visual LISP & DCL
    • .NET, ObjectARX & VBA
    • Application Beta Testing
    • Application Archive
  • Other Autodesk Products
    • Autodesk 3ds Max
    • Autodesk Revit
    • Autodesk Inventor
    • Autodesk Software General
  • Other CAD Products
    • BricsCAD
    • SketchUp
    • Rhino
    • SolidWorks
    • MicroStation
    • Design Software
    • Catch All
  • Resources
    • Tutorials & Tips'n'Tricks
    • AutoCAD Museum
    • Blocks, Images, Models & Materials
    • Useful Links
  • Community
    • Introduce Yourself
    • Showcase
    • Work In Progress
    • Jobs & Training
    • Chat
    • Competitions


  • Programs and Scripts
  • 2D AutoCAD Blocks
  • 3D AutoCAD Blocks
  • Images
    • Backgrounds

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...

  1. josvandoorn


    Dear People, CADTutor has got a name in the AutoCAD community. I was at your web site. I saw your forum. I'm a mem ber of your forum.. You also have a forum that is dealing witgh AutoLISP, Visual LISP & DCL. I did not see AutoLISP programs there. But. I'm wondering. Are you interested in AutoLISP programs? Do you want to publish them? I have written many AutoLISP programs. I'm still writing AutoLISP programs. What is more. I'm writing articles about my AutoLISP programs. I publish them on my blog. If you want to see what I have got. Here is the website of my blog. http://www.speedupautocad.blogspot.com/ If you are interested, let me know. I could send you my articles. Let me know where I can send them to. And what format you want: DOC or text. Jos van Doorn SpeedUpAutoCAD
  2. I am trying to update menses, tools, and LISP routines from autoCAD 2000 to 2011. I was able to load and update most of them except 4 LISP routines. When I open the routine in VisualLISP all I get is a bunch of characters. It does not matter if I use autoCAD 2000 or 2011 to open the routines, it would not show its content. Does anyone know what might be the issue? How to fix it? Thanks
  3. Hello, I am a newbie to AutoLISP and need to write a program to delete all layers in a file except these: Fixture-Shapes, CHECKLANE, Arch-Wall-Interior (Construction), Arch-Wall-Interior, Arch-Wall-Exterior. Here's what I have so far - I'm getting the error message: "error: malformed list on input" (defun c:deletelayer2 (/ ss) ; get layers to keep ; if object not on these layers, delete ; purge - delete empty layers ; select all things NOT on these layers. "_x" is a filter that selects all. (if (setq ss (ssget "_x" ' ((-4 . "<NOT") (8 . "Fixture-Shapes, CHECKLANE, Arch-Wall-Interior (Construction), Arch-Wall-Interior, Arch-Wall-Exterior") (-4. "NOT>")))) (command "._erase" ss "") ; (prompt "\n** Nothing selected ** ") (princ) ) ) Thank you!
  4. I need to create a routine that will allow a user to pick two points (via intersections) and then it will automatically place text (user types in) at the midpoint between these first two points. So far I have: (defun c:textplacer () (command "_textstyle" "standard") (command "_textsize" "6.0") (command "_osnap" "Intersection") (setq pt1 (getpoint "\nSelect First Point:"));gets the first user point (setq pt2 (getpoint "\nSelect Second Point in POG Direction:"));gets the second user point (setq pt3 (abs (- (car pt1)(car pt2))));gets the middle point btw pt1 and pt2 ;need the rest here );end function Not even sure if pt3 is really getting the midpoint...I'm out of my depths here.
  5. theonlynelly

    lisp cannot save

    Dear cadtutor forum, I am new autolisp user (i use autocad civil 3D 2012), i try to coding there but it doesn't have the "Save All" option in the console. How to save the file i've made? Thank you in advance
  6. I want to write my own hatch command. (AutoCAD 2011) In that, I want user to create the hatch manually and then process the hatch object created by the user in my command. Manually, when you type hatch command at the command prompt: "When the ribbon is active, the Hatch Creation contextual tab is displayed. When the ribbon is off, the Hatch and Gradient dialog box is displayed." (from Acad help). However the (command "hatch") statement does not activate the contextual tab even when the ribbon is active. I have tested all combinations with -hatch, -bhatch, cmddia and PAUSE, but without success. Is this 'incomplete' work by AutoCAD Development team? Is there a way to activate the contextual tab using Lisp after (command "xxx") statement? I have searched the forum but could not find anything related. Please help.
  7. Is there anybody who can tell me where can I find information about ALL VLA-... COMMANDS. It's a disaster not to be able to find any information on the help of AutoCAD 2006 and some others about it. Normally it would be possible to run a routine, script, lisp or whatever within AutoCAD and get a result, but it is really an act of faith not to find a-n-y information about it on the help from the program. I would like to know what it's possible and not to do through a lisp routine. Thanks in advance
  8. I have made a program that will draw objects from user input. I offer a simple sample below that will place a dimension on an object. After the DIMLINEAR line I would like to be able to edit the text of the last dimension with the next (4) possibilities (that I will independently use as needed, no need for optional prompt for condition): 1. \XABC ~ for text under dimension 2. ABC ~ for text on same line after dimension 3. ABC ~ for text on same line before dimension 4. ABC 4'-0" ~ for adding text and HARD coded dimension (actual dim replaced) (defun c:bdt () (SETVAR "CMDECHO" 0) (SETQ STP (GETPoint "\nPick Starting Point: ")) (SETQ P2 (POLAR STP (* 2 PI) 5.0)) (SETQ P3 (POLAR P2 (* 3 (/ PI 2)) 5.0)) (SETQ P4 (POLAR P3 PI 5)) (COMMAND "LINE" STP P2 P3 P4 STP "") (COMMAND "DIMLINEAR" STP P4 "@36.0 ? (PRINC) ) I DO NOT know any VLisp and have been searching books and online content with only similar luck. I have found samples that prompt the user to pick a dimension, but, I have many dimensions I want the PROGRAM to create and EDIT each dim at run time. No user interaction. Please help me with the (4) different scenarios I have using the code I have provided. Please, no bells & whistles, will be above my level of experience at this moment. Thanks for any help.
  9. Hi.. as I told before, I am a beginner in LISP, trying to write something, but getting error.. "error: malformed list on input" . what it means? I have list :- ((((1 . x ) (2 . y)) ((3 . z) (4 . a))) (((1 . m ) (2 . n)) ((3 . o) (4 . p))))) I want this as :- (((x y) (z a)) ((m n) (o p))) (defun test1 () (setq gb '((((1 . x ) (2 . y)) ((3 . z) (4 . a))) (((1 . m ) (2 . n)) ((3 . o) (4 . p))))) (setq blanka '()) (setq blankb '()) (setq len1 (length gb)) (setq count1 0) (while ( (setq data1 (nth count1 gb)) (setq len2 (length data1) (setq count2 0) (while ( (setq data2 (nth count2 data1)) (setq blankb (append blankb (list data2))) (setq count2 (1+ count2)) ) ; while (setq blanka (append blanka (list data1))) (setq count1 (1+ count2)) ) ;while )
  10. Hello everyone, does anyone knows a way to define a function in AutoLISP with arbitrary arguments, same as ARX?
  11. Hi all New to this forum and am in search of help. I have been lumbered with a project to take ACAD drawings of a control system into ACAD Electrical. The old version has no use of layers and has text for the wire numbers. What I would like to do is change the text lines to a wire layer thus giving me use of the auto numbering. Additionally I note that the export to spreadsheet does not take all of the attributes of the components i.e. a relay contact shows, when editing the properties, the wire number at each connection but is not in the spread sheet. This woudl be great if it could report this to produce the wiring schedule automatically. So to sum it up is tere anyway to get a lisp progran to change the text object and can it also extract the data I need for the wiring schedule into any form of text file. Cheers Phil
  12. Hi I am making a lisp routine that inserts a block and breaks the line the block is inserted in. The block inserted is a pump schematic which includes the valves, strainer and control points (tags). I use the BREAKDIM attribute (invisible) to set the width of the linebreak that the block is inserted into. (some of you old lispers would remember the code BBlock.lsp ) I am would like to burst the block after inserting it from within the lisp routine. If I use the code (C:burst) It invokes the burst command but prompts me to: select objects. I would like to have it burst the block that was just inserted (entlast) or let me input the block name. Another option would be to use the (command "._explode" "L" "") function and then erase the attribute Def -`BREAKDIM. To do this I would need some code to find an Attribute def (not in a block anymore as it was just exploded) with the TAG "BREAKDIM" and then use the `command "erase" function to delete it. If anyone can help it would be much appreciated. Mbuk
  13. Hey all, I have a quick question. I apologize if this has already been asked, but I can not find it myself. I have searched other spots, but its hard if the thread does not specifically deal with your question. My problem is, we have a LISP routine at my company. After you get all of the information from the user, it will insert a block in a specific arrangement in a specific amount. Like, insert blah blah blah 3 times downward 1 inch apart. Everything works fine, but the problem is is that the block HAS to be in the drawing, otherwise the routine fails. If you run it while the block is IN the drawing, it runs fine, no problems. Help?! I have scoured different ways to have it insert the blocks, but no combination seems to work. Here is the line for inserting the block, any ideas? (command "insert" "terminal" (polar #pt1 1.570796327 0.125) "" "" "")
  • Create New...