Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

CATIA V5 DRAFTING/DRAWING TITLE BLOCK SCALE UPDATE 1

amadali

Student
Feb 26, 2025
7
Hi, I made a custom title block in catia v5 drafting. the problem is when i update sheet scale from properties, the scale does not update automatically in title block. how make the scale box in title block to update automatically when i update drawing scale from sheet properties ?
 
Replies continue below

Recommended for you

Your titleblock text that displays scale should be linked with `Scale` parameter with attribute link.

Code:
set sheet = CATIA.ActiveDocument.Sheets.ActiveSheet
for each param in CATIA.ActiveDocument.Parameters.SubList(sheet, True)
    if InStrRev(param.Name, "ViewMakeUp.1\Scale") > 0 then
        set txt = sheet.Views.Item(2).Texts.Add("", 100, 200)
        txt.InsertVariable 0, 0, param
        exit for
    end if
next
 
Your titleblock text that displays scale should be linked with `Scale` parameter with attribute link.

Code:
set sheet = CATIA.ActiveDocument.Sheets.ActiveSheet
for each param in CATIA.ActiveDocument.Parameters.SubList(sheet, True)
    if InStrRev(param.Name, "ViewMakeUp.1\Scale") > 0 then
        set txt = sheet.Views.Item(2).Texts.Add("", 100, 200)
        txt.InsertVariable 0, 0, param
        exit for
    end if
next
In Catia where to put this code? kindly explain procedure in detail.
 
If you are trying to do it manually versus code.
edit the text, then RMB outside of the text editor window.
choose Attribute link. Then select the sheet, or view from the tree that you want it to reference.
Scroll down to scale, choose it and apply.

250421-Image-003494.jpg

250421-Image-003496.jpg
 
If you are trying to do it manually versus code.
edit the text, then RMB outside of the text editor window.
choose Attribute link. Then select the sheet, or view from the tree that you want it to reference.
Scroll down to scale, choose it and apply.

View attachment 8530

View attachment 8531
great , thanks
 

Part and Inventory Search

Sponsor