vjxzy
Automotive
- Jan 31, 2019
- 13
Language="VBSCRIPT"
Sub CATMain()
Dim DrwDocument As Document
Dim drwsheets As DrawingSheets
Dim drwsheet As DrawingSheet
Dim drwviews As DrawingViews
Dim drwview As DrawingView
Dim DrwTexts As DrawingTexts
Dim DrwText as DrawingText
Set DrwDocument = CATIA.ActiveDocument
Set drwsheets = DrwDocument.Sheets
set drwsheet = drwsheets.item(1)
set drwviews = drwsheets.item(1).views
set drwview = drwviews.item(2)
'msgbox drwviews.item(2).name ////BackgroundView item ID=2 - to find appropriate View
Set DrwTexts = drwview.Texts
Set DrwText = DrwTexts.GetItem("Text.1")
DrwText.text = "ASDF"
End Sub
Sub CATMain()
Dim DrwDocument As Document
Dim drwsheets As DrawingSheets
Dim drwsheet As DrawingSheet
Dim drwviews As DrawingViews
Dim drwview As DrawingView
Dim DrwTexts As DrawingTexts
Dim DrwText as DrawingText
Set DrwDocument = CATIA.ActiveDocument
Set drwsheets = DrwDocument.Sheets
set drwsheet = drwsheets.item(1)
set drwviews = drwsheets.item(1).views
set drwview = drwviews.item(2)
'msgbox drwviews.item(2).name ////BackgroundView item ID=2 - to find appropriate View
Set DrwTexts = drwview.Texts
Set DrwText = DrwTexts.GetItem("Text.1")
DrwText.text = "ASDF"
End Sub