hexagon logo

OUTTOLS Script help

I am using the OUTTOLS script found here but need help modifying it for my needs.

We have a part that gets checked on the CMM then data is written to a csv file to be uploaded to a customers database. However if a part has an OOT dimension we rework the part and check it again. I need a way to evaluate for an OOT condition and if there is one to NOT send any data to my csv file. How can I modify the aforementioned script to pass a variable back to PCD? I will then use that variable in an IF/THEN statement to determine whether or not to export the data. Thanks!
Parents
  • Old, but works very well! The messagebox works fine for me in 2011 MR1.

    This is the code I have in my part program:

    ASSIGN/NUMBEROUTTOL=0
    CS4        =SCRIPT/FILENAME= J:\CMM\REPORTING\SCRIPTS\OUTTOL.BAS
    FUNCTION/Main,SHOW=NO,,
    STARTSCRIPT/
    ASSIGN/NUMOUTTOL=NUMBEROUTTOL
    IF/NUMOUTTOL==0
    END_IF/
    ELSE_IF/NUMOUTTOL>0
    COMMENT/OPER,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
    "Part is Bad. There are "+NUMOUTTOL+" dimensions out of tolerance."
    END_ELSEIF/


    I actually end up with two message boxes, one from the script and one from the above code. That way the operator is sure to see (and hopefully read) one of them. We use this for sending data to a customer database. Data is only sent if no dim's are OOT. If there are OOT dim's the operator must re-work the parts until all dim's are in tolerance.


    Thank you! I will give it a try soon. I am testing this out in 2011 MR1 but the message box gives me the feature and not the actual dimension. Not sure what I am doing wrong...oh well, at least it gives me something....lol
Reply
  • Old, but works very well! The messagebox works fine for me in 2011 MR1.

    This is the code I have in my part program:

    ASSIGN/NUMBEROUTTOL=0
    CS4        =SCRIPT/FILENAME= J:\CMM\REPORTING\SCRIPTS\OUTTOL.BAS
    FUNCTION/Main,SHOW=NO,,
    STARTSCRIPT/
    ASSIGN/NUMOUTTOL=NUMBEROUTTOL
    IF/NUMOUTTOL==0
    END_IF/
    ELSE_IF/NUMOUTTOL>0
    COMMENT/OPER,NO,FULL SCREEN=NO,AUTO-CONTINUE=NO,
    "Part is Bad. There are "+NUMOUTTOL+" dimensions out of tolerance."
    END_ELSEIF/


    I actually end up with two message boxes, one from the script and one from the above code. That way the operator is sure to see (and hopefully read) one of them. We use this for sending data to a customer database. Data is only sent if no dim's are OOT. If there are OOT dim's the operator must re-work the parts until all dim's are in tolerance.


    Thank you! I will give it a try soon. I am testing this out in 2011 MR1 but the message box gives me the feature and not the actual dimension. Not sure what I am doing wrong...oh well, at least it gives me something....lol
Children
No Data