[Ri...] Posted January 22 Share Posted January 22 Probably going to be several more PCM Q's from me, I am adding features and characteristics to a PCM program. What I want to do is Mask and Mark a characteristic if a variable equals "Na". Is this possible? Link to comment Share on other sites More sharing options...
[DW...] Posted January 22 Share Posted January 22 if CONDITION then DEFINITION1 else DEFINITION2 endif Are you trying to mask the characteristic so it doesn't show up in the report? Link to comment Share on other sites More sharing options...
[Ri...] Posted January 22 Author Share Posted January 22 Please sign in to view this quote. Mask and Mark so it is not run or in the report. Link to comment Share on other sites More sharing options...
[DW...] Posted January 22 Share Posted January 22 Please sign in to view this quote. I am a little confused... when you say the variable will be "NA".. can you give an example of what you mean? Link to comment Share on other sites More sharing options...
[Ri...] Posted January 23 Author Share Posted January 23 (edited) If planeB_Flat == "Na" //Mark some features //Mask some features else //Unmark some features //Unmask some features endif Edited January 23 Link to comment Share on other sites More sharing options...
[Ri...] Posted January 28 Author Share Posted January 28 I have found I can get the attribute for masked. getCFAttribute("sphere_loc", "masked") returns "#on" The above is masked in the program. I am thinking I need setCFAttribute to change the attribute, but PCM information is minimal on the use of setCFAttribute. I tried this but it only returns "nil". IsMasked=getCFAttribute("sphere_loc", "masked") setCFAttribute(IsMasked, "off") //returns nil How do you use setCFAttribute? Link to comment Share on other sites More sharing options...
[Ri...] Posted January 28 Author Share Posted January 28 (edited) I have learned how to get the masked value, change the masked value, but I am stuck at setting the masked value to the new value. CF_Attribute=getCFAttribute("sphere_loc", "masked") if CF_Attribute == "on" // if masked, unmask CF_Attribute = "off" setCFAttribute("sphere_loc", "masked") = CF_Attribute endif Edited January 28 Link to comment Share on other sites More sharing options...
[Da...] Posted January 28 Share Posted January 28 I use the condition to show/hide characteristics. Link to comment Share on other sites More sharing options...
[Ri...] Posted January 28 Author Share Posted January 28 Please sign in to view this quote. Either way, I don't know how to change the attribute. Although I haven't thought of using a Condition. Link to comment Share on other sites More sharing options...
[Mi...] Posted January 30 Share Posted January 30 Please sign in to view this quote. Unfortunately, Zeiss doesn't allow you to set the "masked" attribute with the setCFAttribute command. It is only meant for "User-defined characteristic attributes" (see the basic manual). The names of these characteristic attributes have to start with u_. setCFAttribute always refers to the last "used" characteristic (for instance which has been opened by click or addressed with getActual(...)). That's why the characteristics name isn't explicitly an argument of this command. The correct syntax is to hand over the name of the attribute and the desired value: setCFAttribute("u_example", value). Your wish would work if Zeiss hasn't implement the query that the attributes name has to start with u_. Link to comment Share on other sites More sharing options...
[Ri...] Posted January 30 Author Share Posted January 30 Thank you, great explanation. Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in