Regarding scaling in AutoCAD

Regarding scaling in AutoCAD

SaddamShaikh77
Advocate Advocate
523 Views
3 Replies
Message 1 of 4

Regarding scaling in AutoCAD

SaddamShaikh77
Advocate
Advocate

Hello forum,

I am scaling AutoCAD block as below.

var ln=83.375/4.1917; //(6'11"6) converted to inches as (6*12+11+6/16)=83.375

var ht=28.875/1.4517; //(2'4"14) converted to inches as (2*12+4+14/16)=28.875

blockRef.ScaleFactors = new Scale3d(ln, ht, 1);

After scaling block, I should get (6'11"6) and (2'4"14) in output. But I am getting it as (6'11"3/8) and (2'4"7/8) which is shown in the image below

SaddamShaikh77_0-1617718485965.png

Can somebody please assist me to achieve required dimension?

Thank you.

 

524 Views
3 Replies
Replies (3)
Message 2 of 4

SaddamShaikh77
Advocate
Advocate

Can someone please guide? I am stuck due to this in accuracy?

 

0 Likes
Message 3 of 4

essam-salah
Collaborator
Collaborator

Hi @SaddamShaikh77 

actually this uncommon unit format is a bit confusing, if you could post the problem in metric would be be easier to follow.

0 Likes
Message 4 of 4

_gile
Consultant
Consultant

Hi,

6'11"6 is not a valid format.

83.375, converted to inches with the architectural format returns: 6'-11 3/8,and with the engineering format, it returns 6'-11.375"

Have a look at the Converter.DistanceToString method.



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

0 Likes