hexagon logo

Zero out of tolerance features, go to print



I have this code at the end of my programs for the operators to see if anything is out. If there is something out of tolerance then I don't want it to print(make a pdf). how would I write a variable for this to continue to the print/report if its zero out of tolerance.​
  • Take the printing away from your operator and do it automatically by splitting the printing into two If/Endif statement. Remove the OOT comment and have the first IF statement print to PDF when NUMOUT == 0 (not sure why you're set to prompt as that requires the operator to choose where to save the report). Set a location and have it print there every time. Check the Show Report box to have the PDF open after print.

    Have the second IF statement be NUMOUT > 0,and put in the OOT comment on the report instead of operator and print to a temp folder like c:\cmmreports\partnumber_fail.pdf but have it set to overwrite and check the Show Report box. This makes every fail part ran in this program will overwrite the same pdf file.

    This will print and open pdf to your set location if part is good and print, overwrite the pdf in the temp location, and opens the pdf if the part is bad.