Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

How to find the fake dimension in Catia 2D drafting...... 3

Status
Not open for further replies.

CAD2015

Computer
Jan 21, 2006
2,025
Hi,

Let's say we got a 2 D file for revision and suspect that some of the dimension are fake.
Is there any way (other than inspecting every dimension) to find them at once?

Thanks

CAD 2015
 
Replies continue below

Recommended for you

You think dimensions are 'fake'?

Do you mean that you think the automatic dim callout has been replaced with a typed-in value (so that the dim would not update were you to change the model)?

The solution to that depends on what problem you're trying to solve...
 
The engineering department was concerned about a 2D drawing file that had a few dimension that didn't match their expectation. I was put in charge with finding out what was going on.
I found out that one of the dimension was fake (type-in value on Properties).
Tha task is done but I'd like to know if fake dimension could be find easier.......


CAD 2015
 
Turn on the analysis display mode in the visualization toolbar.
Fake dimensions are then brown in color.
190102_Image007_cpoo7y.jpg


Colors are identified here:
190102_Image008_bcbwjr.jpg
 
I have always turn on that option pointed by rickyt.

You can use also the macro below which is doing in fact the search of fake dimensions and color them in red if you don't have the analyze option turned on...

Code:
Language="VBSCRIPT"

Sub CATMain()

Dim drawingDocument1 As Document
Set drawingDocument1 = CATIA.ActiveDocument

Dim selection1 As Selection
Set selection1 = drawingDocument1.Selection

selection1.Search "CATDrwSearch.DrwDimension.DimFakeAttr=TRUE,all"

'Change the color in RED
Set Drwselect = CATIA.ActiveDocument.Selection

Drwselect.VisProperties.SetRealColor 255, 0, 0, 0

End Sub

Regards
Fernando

- Romania
- EU
 
Thank you, RickyT,
Thank you, Ferdo!
[bigsmile]

CAD 2015
 
Fernando,

I have been trying to apply your macro; unfortunately, I got the error messages below:

image_gxivts.png


What went wrong?

Thanks!

CAD 2015
 
I see that you are editing in catvbs...please use CATScript as is written in the header of the code section of the forum Code -> CATScript :)

If you want to use catvbs you need to write ' before each As (this means comment, everything which is after this sign will be ignored) so you will have

Code:
Language="VBSCRIPT"

Sub CATMain()

Dim drawingDocument1 'As Document
Set drawingDocument1 = CATIA.ActiveDocument

Dim selection1 'As Selection
Set selection1 = drawingDocument1.Selection

selection1.Search "CATDrwSearch.DrwDimension.DimFakeAttr=TRUE,all"

'Change the color in RED
Set Drwselect = CATIA.ActiveDocument.Selection

Drwselect.VisProperties.SetRealColor 255, 0, 0, 0

End Sub

Regards
Fernando

- Romania
- EU
 
It works!...
[2thumbsup]
Thanks a lot, Ferdo!

CAD 2015
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor