Message 1 of 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi guys,
I have just realised that the oView.Label.FormattedText is not working anymore. It was working before "Hot-Fix INV19102" and now trows an error.
Try to change the view label like with this code from Curtis:
Dim oSSet As SelectSet = ThisDoc.Document.SelectSet
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
oDescription = "<StyleOverride Underline='True'><Property Document='model' PropertySet='Design Tracking Properties' Property='Description' FormatID='{32853F0F-3444-11D1-9E93-0060B03C1CA6}' PropertyID='29'>DESCRIPTION</Property></StyleOverride>"
oPartNumber = "<StyleOverride Underline='True'> - Mk <Property Document='model' PropertySet='Design Tracking Properties' Property='Part Number' FormatID='{32853F0F-3444-11D1-9E93-0060B03C1CA6}' PropertyID='5'>PART NUMBER</Property></StyleOverride>"
oStringMass = "<Br/><StyleOverride Underline='False' FontSize='0.35'>EST UNIT MASS = <PhysicalProperty PhysicalPropertyID='72449' Precision='2'>MASS</PhysicalProperty></StyleOverride>"
oStringScale = "<Br/><StyleOverride FontSize='0.3'>(Scale <DrawingViewScale/>)</StyleOverride>"
'add to the view label
oView.Label.FormattedText = oDescription & oPartNumber & oStringMass & oStringScale
Else
MessageBox.Show("The selected object is not a drawing view", "iLogic")
End If
It all goes well till seetting the view label.
Thanks.
Adrian S.
blog.ads-sol.com

AIP2012-2020 i7 6700k AMD R9 370
Did you find this reply helpful ?
If so please use the Accepted Solutions or Like button - Thank you!
blog.ads-sol.com
AIP2012-2020 i7 6700k AMD R9 370
Did you find this reply helpful ?
If so please use the Accepted Solutions or Like button - Thank you!
Solved! Go to Solution.