.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Model is out of layout

4 REPLIES 4
SOLVED
Reply
Message 1 of 5
BestFriendCZ
531 Views, 4 Replies

Model is out of layout

Hi all,

 

i wuld like to know if there is easy way how to check this. I know how to find min,max coordinates in my ViewPort. If i transform model cordinates (UCS) to paperspace so these coordinates are still same... doesn't matter to scale setting. Model cordinates change only if i move with model.

 

Reason why i need this is:

our designers use scales like 1:100 if isn't enough then 1:150 and etc.. i can't use zoom extents or something similar

thank you for any advices

layoutExample.png

...
4 REPLIES 4
Message 2 of 5
BestFriendCZ
in reply to: BestFriendCZ

Hi all,

i didn't find some ideal solution. My plan is prepare some logic like:

if model BB is lower then 25m then 1:100 scale

if model BB bethween 25-40m then 1:150 scale

40m and more 1:200 scale

all my structure have profil rectangular so i will compare their width

.... but is really the best solution? i don't think so

...
Message 3 of 5

What about using Zoom Extents to calculate the nearest standard scale?

 


@BestFriendCZ wrote:

Hi all,

i didn't find some ideal solution. My plan is prepare some logic like:

if model BB is lower then 25m then 1:100 scale

if model BB bethween 25-40m then 1:150 scale

40m and more 1:200 scale

all my structure have profil rectangular so i will compare their width

.... but is really the best solution? i don't think so


 

Message 4 of 5

Hi ActivistInvestor
you have right. This is definitely better solution. Thank you for your advice

...
Message 5 of 5
BestFriendCZ
in reply to: BestFriendCZ

//input si CustomScale after use ZoomExtents
public static double FindNearestScale(double input)
{
//1:100, 1:200, 1:150 in order
double[] possibleScales = new double[] { 0.01,0.05,0.006666,};
try
{
return possibleScales.Aggregate((current, next) => Math.Abs(current - input) < Math.Abs(next - input) ? current : next);
}
catch { return 0.01; }
}

...

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

AutoCAD Inside the Factory


Autodesk Design & Make Report