All Activity
- Past hour
-
bustr started following Verify attribute values?
-
Does anyone know how to turn off the setting that prompts to "Verify attribute values"? I am trying to run a script.
-
Maybe select both polylines find the polyline that has the most vertex Then process those vertex with vlax-curve-getClosestPointTo store the mid point of vertex and closest point in a list entmake new polyline with list points.
- Today
-
@pkenewell Thank you very much. I finally got it working. In my case, I set the "length of arcs" to 1. And it worked. But I think the resulting axis isn't very geometrically rigorous. I've attached an example image: -The polyline created by the command is shown in green. -The correct geometry of the axis is shown in dashed red. I think there should be a more geometrically rigorous solution in some older Lisp. Is it possible? Does anyone know of one?
-
ediazg joined the community
-
Finding (and detaching) Raster Image and PDF references in AutoLISP
Jabberwocky replied to Jabberwocky's topic in AutoLISP, Visual LISP & DCL
That did exactly what I needed. Thanks so much! -
The "MC" command by roy437 works for me on your example drawing. You have to set the point resolution (prompt for "Specify Length for arc(ds)") to improve the results. I used 0.1 for pretty good results.
-
The code does not work correctly with polylines that have a large number of segments. Example1.dwg
-
I attach an example Example.dwg
-
@pkenewell Thanks for help. I downloaded the latest code from link and loaded it, but it doesn't seem to do anything. I probably don't understand how it works.
-
@NikonThanks for the code. I tried it. But it only works sometimes. And if the polylines' first point coincides with the last, it doesn't work. Is it possible that I'm doing something wrong?
-
popzz joined the community
-
I can run drafixcad v2.1 with emulator otvdm ( winevdm)16bit installed in windows 11 x64 found on github https://github.com/otya128/winevdm?tab=readme-ov-file Regards Pop
-
-
pkenewell started following Hybrid parallel
-
Look into this post for ideas:
-
Yes you can use the plain ROTATE commad uing the reference option. For example, Command: ROTATE Current positive angle in UCS: ANGDIR=counterclockwise ANGBASE=0 Select objects: 1 found Select objects: pick object then enter Specify base point: vertex 1 Specify rotation angle or [Copy/Reference] <0>: r Specify the reference angle <0>: vertex 1 again Specify second point: vertex 2 Specify the new angle or [Points] <0>: vertex 3
-
Perhaps the most appropriate description is to obtain the axis between 2 irregular polylines
-
Please help me if you know about lisp. Thank you.
Nikon replied to CAD2005's topic in AutoLISP, Visual LISP & DCL
You can also watch here: https://forums.augi.com/showthread.php?53180-Change-color-of-existing-MTEXT-Objects&highlight=remove formating -
sdffd joined the community
-
Dahzee started following Pyramid rotation
-
I'm no 3D expert, but should the OP be using the 2D Rotate if all they are doing is copying the Pyramid onto its side?
-
Copy and paste error (blocks changes!)
rlx replied to X11start's topic in AutoLISP, Visual LISP & DCL
well , downloaded your files on my homedragon and no errors on my side , maybe others can give it a go and see if they get an error? -
mhupp started following Hybrid parallel
-
Posting a drawing would help to be more clear with what your asking for. but maybe this is what your looking for. PAV
-
lrm started following Pyramid rotation
-
Sometimes I find it much easier to use the ALIGN command instead of rotate or rotate3d. In this case just use d' and o' as the source points and points on the x axis for the two target points. The distance from the d' target point to the o' target point is not critical just don't scale the result when prompted.
-
CelsoBlackfyre joined the community
-
Do you need to rotate the pyramid itself, or just the view of it? You can draw it once in model space, then create multiple viewports in paper space to get the diagram you attached. No need to rotate the original pyramid.
-
Hi again. This may also happen to others: sometimes I have two polylines and I need to get something like a common parallel to both. A sort of hybrid parallel from the original two. Is it possible that this topic has been discussed in the history of this forum and there is a LISP to solve this problem? Thanks in advance.
-
Please help me if you know about lisp. Thank you.
Nikon replied to CAD2005's topic in AutoLISP, Visual LISP & DCL
Try this code, calling with command: MtextToByLayerNoNum (defun _strip-mtext-color (s / i j) ;; Deletes all occurrences \C<number>; and \c<number>; (setq i 0) (while (setq i (vl-string-search "\\C" s i)) (if (setq j (vl-string-search ";" s i)) (setq s (strcat (substr s 1 i) (substr s (+ j 2))) i i) (setq s (substr s 1 i)) ) ) (setq i 0) (while (setq i (vl-string-search "\\c" s i)) (if (setq j (vl-string-search ";" s i)) (setq s (strcat (substr s 1 i) (substr s (+ j 2))) i i) (setq s (substr s 1 i)) ) ) s ) (defun c:MtextToByLayerNoNum (/ ss ent elist newtext) (princ "\nSelect Mtext objects to set to ByLayer.") (if (setq ss (ssget '((0 . "MTEXT")))) ; Select only MTEXT entities (progn (vlax-for ent (vla-get-ActiveSelectionSet (vla-get-ActiveDocument (vlax-get-acad-object))) (if (= (vla-get-ObjectName ent) "AcDbMText") (progn ; Set the entity color to ByLayer (color code 256) (vla-put-color ent 256) ; Get the Mtext content (setq elist (entget (vlax-vla-object->ename ent))) (setq newtext (cdr (assoc 1 elist))) ; Strip all internal formatting codes, including color (setq newtext (_strip-mtext-color newtext)) (while (vl-string-search "{" newtext) (setq newtext (vl-string-subst "" "{" newtext)) (setq newtext (vl-string-subst "" "}" newtext)) ) ; Update the Mtext entity with the stripped text (vla-put-TextString ent newtext) ) ) ) (princ (strcat "\n" (itoa (sslength ss)) " Mtext objects updated.")) ) (princ "\nNo Mtext objects selected.") ) (princ) ) -
@Ajmal Thank you this is equally amazing! I now have two versions that cover all scenarios. I can use @Tsuky's version when the quirk dimensions are equal as this version doesnt require as much user input. Then, for the more unusual quirks I can switch to your version and specify the parameters. Thanks guys problem solved! I'm sure I'll come up with a new problem soon
-
@Tsuky Thank you so much this is absolutley amazing! It doesn't allow the width and height to be specified independantly, but considering that the vast mojority of the time these are the same it's really no issue at all to just adjust them when required. Again, thank you