Insert line

I have asked this question a couple of times before but I did get nowhere. Maybe I am too stupid or too old or both. Or I did not properly
describe the problem . Here is my problem:
I want to insert lines in a drawing "start snap - end snap". I wand to be able to trim, stretch champher etc those lines as normal lines. So far no problem.
At the end of the ride I want to extract the length of each line with the attiribute extraction feature.
I have tried with blocks (the block is a line of 1 unit long). I can insert - rotate - stretch etc and extract the length but I can not modify (stretch, trim, join, chamfer...) these lines ones they have been inserted.
I am using Acad 2006 Mechanical. An average drawing contains about 100 - 200 different blocks and maybe 80 - 100 lines as per above description.
Thanks, Daniel
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
If it has to have an attribute, it has to be a block. You cannot do as you say to a block but you can rescale a block until it's length is whatever you need it to be. The result should be the same as if you had edited line, although the work required may be greater. That's the price you pay for working with blocks.
You may need some 'constructive geometry' to do this accurately. After rescaling the block you'll probably want a function to update the length attribute.
At this end, we end up having to accept your assumptions about the efficacy of working this way, I'm afraid.
--


MichaelB
www.michaelbulatovich.ca
  Click to see the full signature.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
dveusa wrote:

the line and the line block look the same on the screen, but the dxf code used to generate them is fundamentally different. Michael is exactly right.
I will just restate because I think there is a communication problem.
a line entity has no attribute to extract, but can be filleted. it has endpoints to modify.
a block entity may CONTAIN a line entity, and can be SCALED or ROTATED but that is not really editing the line entity contained in the block definition. so you will NEVER be able to fillet a block. a block has no endpoints to modify. and if your fillet has a radius, that would be an additional entity within the block definition too.
you could ( this would be real stupid ) explode a block, fillet the line, and recreate the block. I cannot conceive how this would be of any use.
I THINK I KNOW WHAT WOULD WORK FOR YOU:
just use lines ( and arcs if you have rounded corners ) and use the ssget function to sum their lengths at the end of your ride. is this accumlation what you are after?
I never assume anyone is too old or too stupid. you are as old as you are, and smart people can sneak up behind you too easy if you let them tell you they are inconsequential......
:)
hope some of this was helpful.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
............... just use lines ( and arcs if you have rounded corners ) and use the ssget function to sum their lengths at the end of your ride. is this accumlation what you are after? ......................
Exactly. I am not very familiar with AutoLisp but I tried (setq ss(ssget)).... and than (sslength ss).... This returned the number of lines not the length in that part of the drawing. If I just could get the total length than this would save my day. Thank you for helping me out... maybe I am not too old after all.
Daniel.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
Paul Turvill has a lisp to give the total length of selected lines on his website.
--


MichaelB
www.michaelbulatovich.ca
  Click to see the full signature.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
Thanks a lot. I found exactly what I needed.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

Polytechforum.com is a website by engineers for engineers. It is not affiliated with any of manufacturers or vendors discussed here. All logos and trade names are the property of their respective owners.