// Exit script if no front-image found image img if ( !GetFrontImage( img ) ) exit(0) // This line: Exit script if no front-image found ShowImage(img)