Lisp routine to select sheet layouts

Lisp routine to select sheet layouts

Anonymous
Not applicable
1,585 Views
5 Replies
Message 1 of 6

Lisp routine to select sheet layouts

Anonymous
Not applicable

I use 11 X 17 PS title blocks and have several tabs (pages)...which have various viewport layouts. I am trying to create a Lisp routine which will allow me to scroll through the various viewport layouts to select one for the tab I am working on. Basically the title block is Xref'd in - and the layout is already established, I just need to select the appropriate arrangement of vports....The second part of the routine will insert rectangles into model space at the specific location which the vports are zoomed to. For instance, if I have a sheet with 2 vports scaled at 1/4"=1'-0"....upon selecting that vport config, the lisp routine would insert the 2 vports into PS, and also insert 2 rectangles which are the same size as the vport windows at the appropriate scale in MS...and at the location which the vport windows are "viewing"....so that I can just draw inside those rectangles and everything will be arranged....I already have drawings of all these arrangements - but it is not efficient to insert them into a new dwg tab every time. Can anyone  help me with this? 

Dustin

0 Likes
1,586 Views
5 Replies
Replies (5)
Message 2 of 6

maratovich
Advisor
Advisor

Do you want to work the other way around?
Attach an example of your file.

---------------------------------------------------------------------
Software development
Automatic creation layouts and viewport. Batch printing drawings from model.
www.kdmsoft.net
0 Likes
Message 3 of 6

Anonymous
Not applicable

Not sure what you mean by "the other way around"...I have several vport config's for my sheets - depending on need: PLAN, SECTIONS, DETAILS, etc....I would like to do something such as press shift "l" and have a window pop up which contains a list of vport config's (PLAN, SECTION, DETAILS, etc) and when I select one, it would place the vports into my PS sheet and also rectangle dwg's the same size as the vports at a particular scale - such as 1/4"=1'-0" into MS in the spot which the vports are "viewing"....In other words, all I would have to do is draw inside the rectangles in MS and it would already be lined up, etc in PS. I have attached a couple pics to give an example......

 

The first pic is my PS sheet with the vport window (hidden)....

The second pic is my MS dwg with a rectangle which is scaled approp. to 1/4"=1'-0".....in other words, the rectangle is scaled up 48x size....The rectangle is only there as a guide for my vport size while dwg....so I stay within the area.....

 

Annotation 2019-06-19 145155.pngAnnotation 2019-06-19 145422.png

0 Likes
Message 4 of 6

scot-65
Advisor
Advisor
>> The second part of the routine will insert rectangles into
model space at the specific location which the vports are
zoomed to.

Explore CHSPACE. Draw the rectangle first in PS.

Do you use a template (DWT)?
If so, establish a rectangle grid (matrix) of all the "working" areas.
If your workflow requires more than one scale, suggest creating
a dynamic block of the borders with a visible lookup of the different
drawing scales (see below).

"The other way around" - Create views in MS to use in PS.
Model space view creation in LISP form:
(command-s ".VIEW" "Window" a "_non" b "_non" c)

For Paper Space:
(command-s ".VPORTS"... - create the viewport.
(command ".MSPACE") - this sets the viewport as active.
(command-s ".VIEW" "Restore"... - sets the viewport to the defpoint box.
Compose (move) the viewports to fit inside the defined area to plot from.

In my arsonal there are 5 drawing files as dynamic blocks
having defpoint boxes:
1-panel-L (landscape)
2-panel-P (portrait)
4-panel-L
8-panel-P
16-panel-L.dwg

???

Scot-65
A gift of extraordinary Common Sense does not require an Acronym Suffix to be added to my given name.

0 Likes
Message 5 of 6

SAFizzy
Advocate
Advocate

try this may be it will help you

 

http://www.lee-mac.com/tabsort.html

 

0 Likes
Message 6 of 6

Anonymous
Not applicable

I understand what you are saying - and the method you have laid out. I am not entirely sure if it would achieve everything that I want.....The part that I feel may be missing is the reference rectangles in model space which would be at the specified scale (or would scale automatically). I am not sure if I am making sense. We do not use a DWT file for our templates, we use an dwg file with Xref'd titleblocks. One issue we have is that the drafters are not keeping their MS dwg's in an organized, and systematic fashion.....They put different views all over the place and have messy dwg's.....I seek to A0 Make it easier to select the PS Vport layout needed for the particular sheet we are drawing, B) create an organized set of views in MS so that things are neat & orderly and easier to edit, etc. By having the rectangles as a guide in MS, each sheets views would be in a specific order and location, making things much neater & organized. Perhaps I am not thinking of an alternative way to achieve this. Any suggestions?

0 Likes