fix foo pline length

fix foo pline length

Anonymous
Not applicable
1,086 Views
10 Replies
Message 1 of 11

fix foo pline length

Anonymous
Not applicable

Hi all,

 

Can someone have solution to tell me fix foo pline in my file attached. ?

 

Thank you.

0 Likes
1,087 Views
10 Replies
Replies (10)
Message 2 of 11

ВeekeeCZ
Consultant
Consultant

That's property of dimstyle - DIMRND

 

See SCREENCAST

0 Likes
Message 3 of 11

Anonymous
Not applicable

Thanks BeekeeCZ

 

But in my work, if wall 6000 lenght but dim is 6001 then i must strestch to 6000. And in drawing have a lot of wall same. Now i want to fix by lisp walls.

How can do it faster multi wall same by lisp or any way.?

 

 

0 Likes
Message 4 of 11

3wood
Advisor
Advisor

Command: DIMSTYLE

Click Modify button than change settings as below:

Capture.jpg

0 Likes
Message 5 of 11

dbroad
Mentor
Mentor

I really don't think LISP is the best tool to fix poor drafting.  I would consider pink slips or some other financial incentive/disincentive to affect future outcome.  Proper tools include using snap, ortho, polarmode, and direct distance entry.  

 

While it is possible to change the length of a line or polyline, its position and angle and its relationship to other objects, including dimensions, may not always be associative or even implied.  Fix it this time and take care it doesn't happen again.

Architect, Registered NC, VA, SC, & GA.
Message 6 of 11

joselggalan
Advocate
Advocate
0 Likes
Message 7 of 11

ВeekeeCZ
Consultant
Consultant

Don't wanna be a party pooper... I do agree with others. Actually, I see no reason why the decimals even should be there!! The last digit is 0.1 MICRO meter! Construction accuracy is more that 100,000 times higher! It's not precise, it's stupid.

 

Anyway, made you a simple routine to simplify manual stretching - just select the wall (line) closer to corner which should be stretched.

 

Spoiler
(vl-load-com)

(defun c:RoundWall ( / *error* oOSMODE w1 w2 en pt par ds p1 p0 pn)
  
  (defun :Round (x to) (* to (fix (/ ((if (minusp x) - +) x (* to 0.5)) to))))
  
  (defun *error* (errmsg)
    (if (not (wcmatch errmsg "Function cancelled,quit / exit abort,console break"))
      (princ (strcat "\nError: " errmsg)))
    (setvar 'OSMODE oOSMODE)
    (princ)
    )
  
  (setq oOSMODE (getvar 'OSMODE))
  (setvar 'OSMODE 0)
  
  (if (and (setq en (entsel "\nSelect segment to round: "))
	   (setq pt (cadr en)
		 en (car en))
	   (setq pt (vlax-curve-getClosestPointTo en pt))
	   (setq par (fix (vlax-curve-getParamAtPoint en pt)))
	   (setq ds (- (vlax-curve-getDistAtParam en (1+ par))
		       (vlax-curve-getDistAtParam en par))
		 ds (- (:Round ds 10)
		       ds))
	   (setq p1 (vlax-curve-getPointAtParam en (:Round (vlax-curve-getParamAtPoint en pt) 1)))
	   (setq p0 (vlax-curve-getPointAtParam en (if (equal (:Round (vlax-curve-getParamAtPoint en pt) 1) par 1e-06)
						      (1+ par)
						      par)))
	   (setq pn (polar p1 (angle p0 p1) ds))
	   (setq w1 (polar p1 (* 0.25 pi) 1000)) ; (getpoint "\nSelect objects: "))
	   (setq w2 (polar p1 (* 1.25 pi) 1000))  ; (getcorner w1 "\nSpecify opposite corner: "))
	   )
    (command "_.STRETCH"
	     "_box" w1 w2 ""
	     p1 pn))
  (setvar 'OSMODE oOSMODE)
  (princ)
)

 

0 Likes
Message 8 of 11

Anonymous
Not applicable

Thanks all comment.

 

First post is idea unclear, don't need .xxxx (exactly problem everyone think). I am thinking my problem is: example 6000, so distance vertex 1 and 2 is 6001->6002 change to 6000  or 5997->5999 change to 6000. If 6003->6004 change to 6005, 5996->5997 change to 5995. So how do you know that with code.? of course number 6000 = x = integer value. Smiley Very Happy

 

 

0 Likes
Message 9 of 11

Anonymous
Not applicable

 

This problem alway have in my country. Project new and project old same. And many people draw duration project in multi company. So fix it in another company is incapability when them finished project.

 

 

Thanks for your solution.Smiley Very Happy

 

0 Likes
Message 10 of 11

ВeekeeCZ
Consultant
Consultant
Just change 10 to 5 in the :round function.
0 Likes
Message 11 of 11

Anonymous
Not applicable

Yep i just thinking about. If >x.5 then change to up and <x.5 change to down.

Thank you.

0 Likes