This sample saves an image of a screen immediately before the screen data is transmitted and then appends the image to a Word file.
This sample applies only to IBM terminals
This sample handles the BeforeSendControlKey event to run the PutImagesInWordDocument Sub every time the program exits a screen.
PutImagesInWordDocument gets an image of the screen using the GetLiveScreenImage() method on the ScreenHistory object and saves it to a binary file. It assigns an instance of Microsoft Word to the myWordApp variable. Then it gets the log.docx document (if it is open) or opens it and assigns it to the myWordDoc variable.
Finally, it inserts a timestamp, the image of the screen in the binary file, and the user environment to the Word document and saves the document.