How can I divide a line while controlling the segment length?

How can I divide a line while controlling the segment length?

nei3123
New Member New Member
349 Views
14 Replies
Message 1 of 15

How can I divide a line while controlling the segment length?

nei3123
New Member
New Member

I want to divide a line into multiple segments. I did some research and found that AutoCAD has the BREAK command for this purpose. However, it seems that the command only lets me specify the start and end points, without entering a numeric value for the segment length.

So, I’d like to ask:

  1. Is there a way to use the BREAK command while inputting a specific distance value for each divided segment?

  2. If the BREAK command isn’t suitable for this task, is there another AutoCAD command that allows me to divide a line based on a specified segment length?

BREAK command in AutoCAD.png

0 Likes
350 Views
14 Replies
Replies (14)
Message 2 of 15

paullimapa
Mentor
Mentor

How's about the Measure command?


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 3 of 15

nei3123
New Member
New Member

What do you mean? I don't want to measure the distance between the divided lines, but i want to divide the line segment by the distance i want.

0 Likes
Message 4 of 15

paullimapa
Mentor
Mentor

Enter at the command prompt:

MEASURE

select the LINE object

At the Length of Segment prompt: enter the measurement distance you desire for example: 4

Point objects are then inserted at a measured distance of 4 units on the selected LINE

To see these POINT objects enter at the command prompt:

PTYPE

Select one of the other point styles other than the dot and enter Point size like 15 then click OK

paullimapa_0-1758768991259.png

You now should see these POINTs on the LINE exactly 4 units apart starting from the LINE's start point.

FYI: The segment that's left at the end may not be 4 units

paullimapa_1-1758769457439.png

 

 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 5 of 15

imadHabash
Mentor
Mentor

Hi and Welcome to AutoCAD Forum...
you can find your need by using this free utility DivBreak .

 

Imad Habash

EESignature

Message 6 of 15

Simon_Weel
Advisor
Advisor

Measures companion Divide lets you specify the amount of points for a line to be evenly spaced.

0 Likes
Message 7 of 15

Kent1Cooper
Consultant
Consultant

For a start, check out the attached BreakUp.lsp.  It Breaks objects with linearity Up into separate pieces based on linetypes whose names are part of the command names defined.  Read the comments at the top -- it's "under construction," so there's discussion of limitations and possible capabilities to be included.

It does it with the remainder different-length pieces at the ends of equal different length, as linetypes show them.

The sizes of the dashes and gaps [and points in some cases] are based on the linetype and the linetype scale of the drawing, not on a User-specified length.  But it could pretty easily be modified to ask for that, both for the dash pieces and the gaps.

Kent Cooper, AIA
Message 8 of 15

nei3123
New Member
New Member

I still don’t quite understand how to evenly divide points along a straight line like that. If possible, could you make a video tutorial? I feel that this guide isn’t very optimized, so if you have a better method, could you show me instead?

0 Likes
Message 9 of 15

nei3123
New Member
New Member

Thank you for sharing the Divide command. What I want is to enter the spacing distance between the points along a line, rather than specifying the number of points on the line. If the Divide command has an option to input the spacing distance, I would be glad to know about it. Otherwise, I guess Divide might not be the command I’m looking for.

0 Likes
Message 10 of 15

imadHabash
Mentor
Mentor

>> What I want is to enter the spacing distance between the points along a line

You can try with MEASURE Command. This command is used to place points or insert blocks along entities at equally-spaced intervals based on a specified distance.

Imad Habash

EESignature

0 Likes
Message 11 of 15

paullimapa
Mentor
Mentor

Same as my response from the very beginning 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 12 of 15

nei3123
New Member
New Member

Hi, I have installed and tried using it. However, it seems like there is an error with the length value I entered. I typed in 1 mm, but I don’t see any spacing that matches 1 mm. Could something be going wrong?

0 Likes
Message 13 of 15

nei3123
New Member
New Member

Do you have a detailed guide for the BreakUp LISP? I’m not familiar with how to interact with a LISP routine. What command should I type, and what should I enter to meet my requirements?

0 Likes
Message 14 of 15

Kent1Cooper
Consultant
Consultant

The command names [as in all AutoLisp-defined commands] are all in code lines that start like [for example] this:

(defun C:BU-HIDDEN

in which the part that follows the C: [the red part] is the command name.  Type that in, select valid objects [as many as you want], and they will be Broken Up into pieces with gaps emulating the HIDDEN linetype.  There's one for each of AutoCAD's standard linetypes that involve only dashes and gaps [none of the ones with Shape or Text inclusions].

To make your specific example possible, I am developing [at another location] one that will take input on dash and gap sizes from User input, instead of being based on AutoCAD's linetypes [which don't include any with the gap size the same as the dash length, as it appears you want].  Maybe some time this week....

Kent Cooper, AIA
0 Likes
Message 15 of 15

Kent1Cooper
Consultant
Consultant

@Kent1Cooper wrote:

..., I am developing ... one that will take input on dash and gap sizes from User input, instead of being based on AutoCAD's linetypes [which don't include any with the gap size the same as the dash length, as it appears you want].  Maybe some time this week....


Try this out -- BreakUpU.lsp  -- the last U stands for "including User-input option on dash-gap sizes," which was added -- it still has all the other linetypes' commands.

The command to spell out your own Dash & Gap sizes is BU-UserDG.  It does things like this, where you can specify your own Dash and Gap sizes in different proportions than in AutoCAD's linetypes:

Kent1Cooper_0-1759154463435.png

[Some pieces are selected/gripped/highlighted to show that they're separate pieces, but they all came from one Line and one Arc as source objects.]

It remembers your custom Dash & Gap sizes, and offers them as defaults on subsequent use.

Still in progress in some of the same ways as before.  So far, the only User-specifiable configuration is for one dash and one gap -- maybe some of the other sequences will come later.

Kent Cooper, AIA
0 Likes