Author Topic: set dimscale according to border size  (Read 3025 times)

0 Members and 1 Guest are viewing this topic.

jlogan02

  • Bull Frog
  • Posts: 327
set dimscale according to border size
« on: November 15, 2019, 03:53:30 PM »
We don't use paperspace, so we have 4 borders of varying sizes to accommodate scaled drawings.
I have a routine that currently checks the dimscale and inserts a new attributed title block and border to replace the existing one. This all works great provided the dimscale is correct. If it's not things don't go as planned.

Seems to me I need to...
Check the current dimstyle
If it is annotative, make it X dimstyle. ;;easy enough

Find the length of the bottom segment of the polyline border. ;;I've found examples, seems doable.

If dimscale isn't equal to the segment length, make it so. Now...it's not really equal but you get the point. The line would be X long with Y dimscale and Z long with AA dimscale ;;not a clue on how to accomplish this.

Maybe make a list of the standard dimscales and a list of lengths for the bottom segment line to check against. I don't know...I feel like I'm guessing.
J. Logan
ACAD 2018

I am one with the Force and the Force is with me.
AutoCAD Map 2018 Windows 10

tombu

  • Bull Frog
  • Posts: 288
  • ByLayer=>Not0
Re: set dimscale according to border size
« Reply #1 on: November 15, 2019, 04:12:29 PM »
Not that plotting from Model Space makes any sense to me, but if I was to attempt it I'd set MSLTSCALE to the scale needed for plotting first since an annotative scale would work for all your plot sizes. Then inserts a new attributed title block to match the MSLTSCALE value.
Tom Beauford P.S.M.
Leon County FL Public Works - Windows 7 64 bit AutoCAD Civil 3D

jlogan02

  • Bull Frog
  • Posts: 327
Re: set dimscale according to border size
« Reply #2 on: November 18, 2019, 11:00:20 AM »
You're going to have to explain this more because I don't see how addressing plotting helps my situation at all. My problem is inserting a new title block at scale in drawings that are NOT supposed to have Annotative anything.

Don't get me wrong, I agree that paperspace is the better method for plotting. I've been trying to get that changed for 20 years. 20 years!!!! It ain't going to change. Even if it did change it still wouldn't address the issue of having some existing annotative drawings and some non-annotative while trying to insert an updated title block in drawings currently using scaled title blocks in modelspace.
J. Logan
ACAD 2018

I am one with the Force and the Force is with me.
AutoCAD Map 2018 Windows 10

tombu

  • Bull Frog
  • Posts: 288
  • ByLayer=>Not0
Re: set dimscale according to border size
« Reply #3 on: November 18, 2019, 11:36:02 AM »
Sorry, MSLTSCALE wouldn't help you at all. Maybe if the Annotation Scale was set first you could use one border inserted at a scale of 1/ CANNOSCALEVALUE for whatever scale you're using.

Maybe use EXTMIN & EXTMAX to calculate how big a border you will need.

I should have skipped this one, not an area I'm that familiar with.
Tom Beauford P.S.M.
Leon County FL Public Works - Windows 7 64 bit AutoCAD Civil 3D

jlogan02

  • Bull Frog
  • Posts: 327
Re: set dimscale according to border size
« Reply #4 on: November 18, 2019, 12:10:37 PM »
Not a problem. You had me thinking I was missing something there for a second.
J. Logan
ACAD 2018

I am one with the Force and the Force is with me.
AutoCAD Map 2018 Windows 10

jlogan02

  • Bull Frog
  • Posts: 327
Re: set dimscale according to border size
« Reply #5 on: November 18, 2019, 12:12:06 PM »
The extmin, extmax idea might be something to look at though. Thanks.
J. Logan
ACAD 2018

I am one with the Force and the Force is with me.
AutoCAD Map 2018 Windows 10

ronjonp

  • Needs a day job
  • Posts: 7526
Re: set dimscale according to border size
« Reply #6 on: November 18, 2019, 12:40:50 PM »
You're going to have to explain this more because I don't see how addressing plotting helps my situation at all. My problem is inserting a new title block at scale in drawings that are NOT supposed to have Annotative anything.

Don't get me wrong, I agree that paperspace is the better method for plotting. I've been trying to get that changed for 20 years. 20 years!!!! It ain't going to change. Even if it did change it still wouldn't address the issue of having some existing annotative drawings and some non-annotative while trying to insert an updated title block in drawings currently using scaled title blocks in modelspace.
20 years of plotting out of modelspace! You're a very patient person.  :lol:

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

DeeGeeCees_V.2.0

  • Newt
  • Posts: 154
Re: set dimscale according to border size
« Reply #7 on: November 19, 2019, 02:35:37 PM »
I worked for a few places that had legacy CAD files like that and wouldn't change. Turrible places. lol

I'd go with grabbing the scale factor of the title block and then set the dimscale accordingly.

Titleblock scale = 1
Dimscale = 1

...or something similar.

PKENEWELL

  • Bull Frog
  • Posts: 309
Re: set dimscale according to border size
« Reply #8 on: November 19, 2019, 06:23:59 PM »
I worked for a few places that had legacy CAD files like that and wouldn't change. Turrible places. lol

I'd go with grabbing the scale factor of the title block and then set the dimscale accordingly.

Titleblock scale = 1
Dimscale = 1

...or something similar.

Agreed. I also had to work at shops that refused to use anything but Model space. However if your title blocks are not BLOCKs but only text and lines, that's not going to work. I would hope that's not the case. You could also use the scale factor of the Border BLOCK if you can't use the title block.
EDIT - I see in the OP that the title blocks ARE actually attributed blocks.

The only other option would be to hard code the 1:1 scale of the border into the Lisp (or into the registry or a file that you can retrieve), do a bounding box on the border lines, then compare the X distance of the actual Border with the 1:1 size. I had a program to insert borders and title blocks years ago, but it would set the Dimscale at the same time the scale was prompted for the Border insert.
« Last Edit: November 19, 2019, 06:27:01 PM by PKENEWELL »
"When you are asked if you can do a job, tell 'em, 'Certainly I can!' Then get busy and find out how to do it." - Theodore Roosevelt