Jump to content

Search the Community

Showing results for tags 'lselsetp'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • 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

Categories

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

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 1 result

  1. Dear All, I have a problem replacing blocks (titleblock) which is sometimes a dynamic block. When replacing blocks with a new one i get a lselsetp nil error when there is a dynamic block involved. What i try to do is the following: - I try to replace the block by finding it by name (so no manual selection is needed because of a script) - read the coordinates of the old block - read the scale of the old block - delete the block - purge all unused blocks in the drawing - insert the new one in the drawing at the right scale and coordinates The A0KILL does work for static blocks but someone used dynamic ones in our drawings. Now i have to do these blocks by hand for 15000 drawings. Can anyone help me with this issue? (Old blockname is OHTITLE the new one OH-TITLE) (DEFUN C:A0KILL() (setq OHINS (cdr (assoc 10 (entget (ssname (ssget "X" '((2 . "OHTITLE"))) 0))))) (setq OHX (cdr (assoc 41 (entget (ssname (ssget "X" '((2 . "OHTITLE"))) 0))))) (setq ss (ssget "X" '((0 . "INSERT")(2 . "OHTITLE")))) (command "_.erase" ss "") (repeat 3 (command "_.purge" "_B" "*" "_N") ) ; end repeat (command "-insert";Command "K:\\AutoCAD Standaard\\2014\\ALGEMEEN\\Kaders\\Titelh\\Nederlands\\A0\\OH-TITLE.DWG" ;Block Name OHINS OHX "" ) (setq OHINS nil) (setqoh OHX nil) (setq ss nil) )
×
×
  • Create New...