Message 1 of 3

Not applicable
12-04-2019
08:04 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I'm looking to autofill the View label in the Base View dialog box. in the past, I used some code that adds the words in the Format Text dialog box (see code below). This however, doesn't change the view name in the model browser.
Thank you for your help.
'Adds View Label Dim oSSet As SelectSet = ThisDoc.Document.SelectSet Dim oDoc As DrawingDocument = ThisDoc.Document Dim oSheet As Sheet = oDoc.ActiveSheet If oSSet.Count = 0 Then MessageBox.Show("You must select a drawing view first", "iLogic") Exit Sub End If 'Reference to the drawing view from the 1st selected object Dim oView As DrawingView = TryCast(oSSet.Item(1), DrawingView) If oView IsNot Nothing Then oView.ShowLabel = True 'format the model iproperties oView.Label.FormattedText = "ISOMETRIC VIEW" oStringScale = "<Br/><StyleOverride FontSize='0.5'>SCALE <DrawingViewScale/></StyleOverride>" 'add to the view label oView.Label.FormattedText = "ISOMETRIC VIEW" oView.Label.HorizontalJustification = HorizontalTextAlignmentEnum.kAlignTextCenter Else MessageBox.Show("The selected object is not a drawing view", "iLogic") End If
Solved! Go to Solution.