Search the Community
Showing results for tags 'folder'.
-
HI, I need to create a Lisp to do the following in a series of drawings within a folder and then save as a new file. Superflatten entire drawing. Audit and fix errors. overkill entire drawing Convert all. Purge all. Remove Hatching. Remove DIms. Create boundary box from most southern and most western extremities of building. move boundary box and content from basepoint to be 2000,2000 from 0,0. Id like to type "deepclean" as command in future, I have over 1000 drawings to run this on so ideally id like to find a routine which will automatically do this to all files within a folder, without the need to manually open each one?
-
Newbie question I need to strip out the main root from the directory path. I use this to get the path: (setq dfil (getfiled "Directory listing" "" "dwg" 2)) (setq Filepath (vl-filename-directory dfil)) This returns for example: "C:\\Blocks\\2dlib\\Cars\\Plan" How do I turn the above result into: "2dlib\Cars\Plan" stripping out "C:\\Blocks\\" and only 1 backslash between directories? "C:\\Blocks\\2dlib\\Trees\\Plan" > "2dlib\Trees\Plan" "C:\\Blocks\\2dlib\\People" > "2dlib\\People" Many thanks Zakwaan
- 5 replies
-
- folder
- directories
-
(and 1 more)
Tagged with:
-
Lisp to replace attributed blocks in dwg files on a folder.
CafeJr posted a topic in AutoLISP, Visual LISP & DCL
Hi Guys, Someone knows a Lisp used to replace a internal block(s) of a folder with dwg many files. Eg: The specific folder has a "n" files with A3 formats blocks using the same attributes and tags, so, if it's necessary do a correction in a little detail in this format, it's necessary to replace it, one by one on all of these files. Thanks in advance... -
Part file location in title block?
andrewmmccallum posted a topic in AutoCAD Drawing Management & Output
Hello, I’m trying to save myself a bit of time and was wondering if it is possible to have part of the file location displayed in the title block? The current title block we are using shows the full file location of the drawing but I was wondering if it is possible to show only part of this? The reason I am asking is that when a project progresses to the next stage we have to go through each drawing and change the status to warrant, tender, construction etc. so I am looking for a way that this can be done automatically and I was thinking if only part of the file location could be used this process could be done by simply moving the drawings to the next folder? Our projects folders are split down in to subfolders for planning, warrant, tender etc. which corresponds with the status field on your layout. So instead of having to update this status manually every time the project progresses this would update to the folder that the drawings are in. Example: I:\Projects\## - Project Title\Drawings\Construction\Ground Floor Plan.dwg Am trying to get the "Construction" folder to display in the status field on the layout. I hope this makes some sort of sense and someone knows what i am trying to get at. If there is another way to achieve what I am looking for all suggestions are welcome. -
Is it wise to load all LISP codes at ACAD startup?
khoshravan posted a topic in AutoLISP, Visual LISP & DCL
Maybe it is better to ask the question in this manner: What is the best way to manage the LISP codes and know when to load which code from which address. Maybe it is not wise to load all codes at ACAD startup as it is related to loading, I can assume it consumes bits and bytes and make the program fat which is not good. But my problem is that: When number of codes are handful, there is no problem remembering the name and what they do, but when they increase it is hard to know which LISP is necessary and in which folder I should look for it? How the you guys manage your LISP codes? -
Hello CADTutor members, I found a code by Lee Mac to open a folder by AutoLISP here. The code follows: (defun MT-Explore (Directory / Shell result) (setq Shell (vla-getInterfaceObject (vlax-get-acad-object) "Shell.Application" ) ) (setq result (vl-catch-all-apply 'vlax-invoke (list Shell 'Explore Directory)) ) (vlax-release-object Shell) (not (vl-catch-all-error-p result)) ) Should anyone know how to close the opened folder?
-
Highlight a file in a folder by AutoLISP code
Ahankhah posted a topic in AutoLISP, Visual LISP & DCL
Hello CADTutorians, How can I highlight (select) a file after opening the containing folder by AutoLISP? -
Hello everyone: I'm updating some old code of mine and I want to get ride of using the shell command, you know why. I need to create a folder, this is what's written now to create the folder num_br: (setq commd (strcat "md " "