Jun-05-2020, 02:37 AM
The image is being garbage collected because the only reference to image is destroyed as soon as the code returns from view_records.. Try using a global variable or an instance variable instead of the local variable "image" in method "view_records".