Match block orientating to layout

Match block orientating to layout

Anonymous
Not applicable
1,030 Views
2 Replies
Message 1 of 3

Match block orientating to layout

Anonymous
Not applicable

In AutoCAD it is possible to set the orientating of a block to the orientating of the layout.

This can be done to run the " block" command, select the block to change, and and activate " Annotative"  and " Match block orientating to layout"

 

For example, you may want to have a block presenting the locating of an elevator automatically orientated to every layout.

In a layout with a rotated viewport by 90 degrees, all the elevator blocks are shown according the layout.

 

Is it possible to set the block orientating to match the layout in .NET ?

 

Is it possible to set the block orientating to match the layout even the block is not annotative?

 

Any example in C# or vb.NET would be fine

0 Likes
1,031 Views
2 Replies
Replies (2)
Message 2 of 3

arcticad
Advisor
Advisor

http://www.theswamp.org/index.php?topic=39544.0

---------------------------



(defun botsbuildbots() (botsbuildbots))
0 Likes
Message 3 of 3

Anonymous
Not applicable

Thanks it works

But you have to be sure that the block is allready an annotative block

 

Otherwise you have to set it first:

 

Dim btr As BlockTableRecord = trx.GetObject(bt(sBlockName), OpenMode.ForRead)
    
If btr.PaperOrientation <> bAllignToLayout Then 
        btr.UpgradeOpen()
        btr.Annotative = 0  '  first annotative state (default)
        btr.SetPaperOrientation(bAllignToLayout)

end if

0 Likes