Jump to content

Table OK/NOK sign for dimensions in trend project


---
 Share

Recommended Posts

Dear GOM Team,

I would like to make an extra column in the "Statistic RPS" table format which shows if a dimension (row) fails on any of the stages. So for ex. if a dimension fails on any stages it shows 'nOK' other way it shows 'OK'.

Besides I would like to make a "functional label" on the first page (title) which shows if any of the dimensions from the elements fails. Also OK/NOK sign or any kind of sign would be good.

Do you have any nice solution for these?

 

Best regards,

Máté Tömöri

Link to comment
Share on other sites

  • 3 weeks later...

Hello Máté,

for the OK/nOK column you could insert this expression:

#@ OK nOK Check
niO = "nOK"
iO = "OK"
if result_worst_case < result_dimension.lower_tolerance_limit or result_worst_case > result_worst_case.upper_tolerance_limit:
	a =format (niO, "", show_unit=false, color=color ("#ff0000ff"))
else:
	a = format (iO, "", show_unit=false, color=color ("#13d373ff"))
return a

It checks if the worst case is out of your tolerances. For the tolerance status you could use the Keywords project_statistics.all.number_of_within_tolerance and project_statistics.all.number_of_toleranced_attributes in a label on the title page. They are also available for individual element types. The label needs the information from a 3D view, so there has to be a placeholder for this on the title page with all checks visible somewhere. The size doesn't matter though, it could be tiny or behind some element.

#@ Not yet named
#@ OK nOK Check
niO = "nOK"
iO = "OK"
if project_statistics.all.number_of_within_tolerance < project_statistics.all.number_of_toleranced_attributes:
	a =format (niO, "", show_unit=false, color=color ("#ff0000ff"))
else:
	a = format (iO, "", show_unit=false, color=color ("#13d373ff"))
return a

Snag_2eb30317.thumb.png.d9f21cc1d1653f4eb90a472e4ed79f31.png

Regards,

Nanno

 

Link to comment
Share on other sites

Hello Nanno,

 

Thanks, we are getting closer but not work properly yet.

The table and the title page also just shows the actual stage. Worst_case depend on the actual stage too unfortunately.

My idea is to insert somehow Min/Max (from Statistic Overview) to your expression but some problems occured what I could not handle.

 

Best regards,

Máté

 

1.thumb.PNG.cd851f1c2521094bc2a7668322ccdb2e.PNG

2.thumb.PNG.f8224f7b180787b87dbf1d168c5a668a.PNGp1.thumb.PNG.c57601126996f3ba7ab4f0bed720f105.PNGp2.thumb.PNG.5954b91a8b9b9cdb2548d2ba731946ae.PNG

Link to comment
Share on other sites

Hello,

For a similar functionality I count the number of result_dimension.out_of_tolerance. The number of stages (parts) that are out of tolerance

count (result_dimension.out_of_tolerance>0, index='stages')==INVALID?
	"0": 
    format ((count (result_dimension.out_of_tolerance<0, index='stages')
             +count (result_dimension.out_of_tolerance>0, index='stages')), "1.0", show_unit=false)

(of topic:
I didn't know the python if then else syntax could be used in a expression)

Link to comment
Share on other sites

Hello,

I solved the first problem include min/max into the function.

I still could not solve the second question which is how to show on one label that all the dimensions are good or not.

 

------------------------

for general dimensions:

#@ OK nOK Check

niO = "nOK"
iO = "OK"


if result_dimension.is_tolerance_used:
    
    if (max (result_dimension.deviation)) > result_dimension.upper_tolerance_limit or (min (result_dimension.deviation)) < result_dimension.lower_tolerance_limit:
        a =format (niO, "", show_unit=false, color=color ("#ff0000ff"))
    else:
        a = format (iO, "", show_unit=false, color=color ("#13d373ff"))

else:
    a = ''

return a

-----------------------

for Gdnt:

#@ OK nOK Check

niO = "nOK"
iO = "OK"

if result_gdat_size.is_tolerance_used:

    if (max (result_gdat_size.deviation)) > result_gdat_size.upper_tolerance_limit:
        a =format (niO, "", show_unit=false, color=color ("#ff0000ff"))
    else:
        a = format (iO, "", show_unit=false, color=color ("#13d373ff"))

else:
    a = ''

return a
 

Ok_nOk sablon.package

Link to comment
Share on other sites

 Share

×
×
  • Create New...