Jump to content

Search the Community

Showing results for tags 'table'.

More search options

  • 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...

Found 53 results

  1. Hi everyone, I would like to read a table that would be linked with block attributes. Like a table (either AutoCAD or Excel) of fluids with pressure, temperature, flowrate... that I would link to attributes. I tried to insert a field in the attribute, but what I've found in fields are properties like Color/Layer/Column/Rows ... Anyone could help? Guiboard
  2. I am currently using AutoCAD LT, and I have been racking my brain trying to figure out how to create a table using a simple script. Is this even possible with LT, and if so, does anyone have any helpful advice?
  3. I have done a fair bit of web scouring to find a good method for replacing multiple blocks. There are some pretty decent vba codes out there for block replacement, the Office Optimum "Replace Block" tool, for instance worked okay, but you have to buy it. I have also found some effective .NET solutions for importing block definitions from another drawing to override the definitions in the current drawing. However I keep wondering if there is a good (free) solution for replacing and redefining large numbers of blocks using lisp. I am sure it must be doable. I know this has been discussed before here, but I haven't seen anything yet which uses a simple customisable table to handle lots of replacements at once (Please chastise me if I'm wrong). There are lots of 'piece meal' type block replacement lisps on offer, which rely on either specifying block names from drop down lists, or selecting blocks on the screen. I want something which handles lots of block exchanges at once. I would ideally like a lisp which allows me to set up a table of existing block names, with the filepath for the replacement block along side it. I would like it to resemble this lisp for renaming blocks (i.e. using a table): (defun c:renameb (/ btable badt) (setq btable '(("OLDNAME#1" . "NEWNAME#1") ("OLDNAME#2" . "NEWNAME#2") ("OLDNAME#3" . "NEWNAME#3") ("OLDNAME#4" . "NEWNAME#4") ("OLDNAME#5" . "NEWNAME#5"))) (foreach b btable (cond ((and (not (tblsearch "BLOCK" (cdr b))) (tblsearch "BLOCK" (car b))) (command "_.RENAME" "_Block" (car b) (cdr b))) ((tblsearch "BLOCK" (cdr b)) (setq badt (cons b badt))))) (and badt (prin1 badt) (alert "Unable To Rename All BLOCKs")) (prin1)) I want a block replacement lisp which uses a table to identify the filepath of the replacement block. I also want the routine to tell AutoCAD to replace the definition of any existing blocks with the same name as the one being brought in. Alanjt notes here that the use of the equals sign in the following line achieves that: (vl-cmdf "_.-insert" (strcat nb "=") nil) I also want to preserve the attribute values in the existing drawing. I want to be able to control the scale of the blocks being brought into the drawing as replacements. I want to ATTSYNC replacement blocks. Marijn incorporated the following in a reply to a thread posted yesterday. See here. (if (tblsearch "BLOCK" "OLDNAMEOFBLOCK") (progn (command "-rename" "b" "OLDNAMEOFBLOCK" "NEWNAMEOFBLOCK") (command "_.-insert" "NEWNAMEOFBLOCK=FILENAME" "y" nil);replaced convert template to new template. (command "_.attsync" "n" "NEWNAMEOFBLOCK") (scl 0.8 "NEWNAMEOFBLOCK");scales block to new scale (blknr13 "NEWNAMEOFBLOCK"); this was command to set a block the a layer. (not included can eb removed) )) This takes care of the ATTSYNC and the scale specification. I'd like the OLDNAMEOFBLOCK and NEWNAMEOFBLOCK to essentially be variables, which draw on a pre-defined table to derive values and then apply the commands. Is this possible? I guess I'd be just as happy to input all the values one by one in an unhealthily long code, but a more streamlined answer would be nice. By the by, Marijn's code aimed to incorporate replacing tag names also, when one block is replaced. Interesting. Haven't tried it out properly yet. I would greatly appreciate some assistance in addressing and integrating the requirements outlined above in one amazing 'table based' lisp. I have already sent a post card to Santa politely asking for this for Christmas, so if I'm unsuccessful here, I always have christmas day as a backup.
  • Create New...