Questions from beginner to advanced. Tell us about good sources of free lisp and post your own routines for testing.Code posting guidelines
The "AutoLISP, VBA, the CUI & Customisation" forum has become a very lively part of the AutoCAD Forums and probably needs a structural review in order to acommodate growth in the future. I'm...
Code posting guidelines
When you are posting AutoLISP or VBA code in these forums, there are some simple guidellines you should observe in order to make life easier for you and for others.
How can i code autolisp script to toggle freeze/thaw specific layer?
If x layer is frozen thaw it and vise versa
Hi experts, Need lisp to fast-connect points that are ALMOST horizontal or vertical aligned. It will ask for 1)pick first point 2) Go North, South, East or West 3) fuzz/tolerance distance left or...
(setq scale (getint " Enter the scale:"))How can I feed a default scale.
And after feeding a new value can I auto load it next time
بسم الله الرحمن الرحيم
الحمد لله وحده و الصلاة و السلام على من لا نبي بعده ،، و بعد
In the Name of Allah, the Most Beneficent, the Most Merciful
Dear kind members :
I have a question :
I’m facing a sorting problem: in a drawing there are a number of circles that were placed in sets of 4 along arbitrary axes. The data that I have are the coordinates of the centers for those circles...
Hey Guys ...
Here i need Little Help
(setq ename(vlax-ename->vla-object ss))
(setq points(vlax-safearray->list (vlax-variant-value(vla-get-coordinates ename))))
See here the lisp returned ...
In trying to validate some file names I need to read the 5th character in a string and confirm it's an integer . I know how to grab the 5th character in the string but how does one confirm it's a...
When I run this lisp with a script using Autoscript, all the code to change layers, etc. works fine, but it does not always zoom to extents and save in the zoomed position... only sometimes. I could...
I am trying to write a routine to load a new Plot Style Table, and then set a certain Plot Style Name to all layers.
Here is the code I use to set the new Plot Style Table, and it works fine:
How to replace this characters / or \ in the string
(setq usuario (vl-string-subst "" "\\" usuario))
But not is ok, characters don't replace
Just experimenting with the 'while' function and looking for feedback as to the quality of my coding.
(defun c:test (/)
(setq count 0)
(setq 5dig (getint "\nEnter a 5 digit number: "))...
i'm trying to find a lisp to import tables in a .txt file to autocad but i dont know where to start this task. i had an idea that is :
copy the tables to excel and then paste in...
Does anyone know if using function:
(setq gr (grread T 15 0) vt (CADR g) cd (car gr))
vt code is the same when I press a button on a toolbar (eg "Object Snap") ?
OK, so everyone knows that using the IDE with AutoLISP you can enter a closing paren and the cursor will quickly flash at the location of the opening paren which the one just typed is paired to. Now...
Is it possible to close a windows application via lisp? ie mspaint, excel or word. Thanks.
some example of 'specified condition' need are;
- hide all EXCEPT text entity of only integer number with only 10 digits
- hide all EXCEPT text entity of only alphabet letters with only 10...
i am trying to update my code which is as follows, which i am using to get X,Y,Lat,Long,Bearing & Distance of attribute block from center location :
(defun c:1 (/ file dta p i)
I want to drawn LINE by excel data to autocad 2010, I have excel file x,y and z coordinates.
I want to draw line to import excel data coordinates to autocad ?
Please send the steps / procedure...
In the interest of keeping this Post as short as possible.
I am trying to make a program that converts a BMP to a list of coordinates with color.
(setq p1 (getpoint "/ Pick on insertion point"))
(setq x (car p1))
(setq x1 (/ x 1000))
(command "text""j""ML" p1 100 0 x1 )When I pick a point it insert the x value, but how can reduce...
I am hoping there's a routine out there already that would do the following, although I could not find one on the site. I am reaching out to you experienced programmers out there.
I need a lisp...
How do I connect to and use AutoCA mechanical API using Visual Lisp.
I have tried hard but can't find how to do this.
I am using LEE MAC's code for getting attribute value which is as follows :-
(defun LM:vl-GetAttributeValue ( block tag )
(setq tag (strcase tag))
I have the below code that I use to insert a light fitting as a block. It prompts for the room size and number of light fittings. I'm wondering if there is a way to draw a polyline between...
Well, i am relly newbie programing in AutoLisp, but i would like send you a question about renaming "attribute value" into a block with the commandLine I.ve got this problem, a topography plan with...
Use this control to limit the display of threads to those newer than the specified time frame.
Allows you to choose the data by which the thread list will be sorted.
Order threads in...
Note: when sorting by date, 'descending order' will show the newest results first.
Conceived, created and cared for by David Watson © 1996–2014