• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Printing certificate with javascript problems

Explorer ,
Nov 16, 2018 Nov 16, 2018

Copy link to clipboard

Copied

I have a course completion certificate that allows the user to enter their name and the course name in text input fields.The text entered is assigned to variables that are used to create a printable certificate on another slide.  Clicking my Print button jumps to that slide. On entering the slide I execute the Javascript "window.print()" command which opens the printer dialog to print a hard copy.  The Captivate will be published in HTML5 only.

Problem 1: the printer dialog opens before the slide contents are fully loaded. So the only thing that prints is a background image - not user name and course name.

Problem 2: the slide image is smaller than it should be and pushed to the right edge of the page with a lot of blank space on the left.

I thought of somehow trying to trigger the print action later in the timeline after slide contents finish rendering but there doesn't seem to be any action that can be triggered that way - at a certain time or when an object loads.  As to the scaling problem, Scale to Fit when publishing doesn't help.  I don't know if there is a way to do it with Javascript.

Anybody know of fixes for this?

Views

221

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
Nov 16, 2018 Nov 16, 2018

Copy link to clipboard

Copied

LATEST

I chose not to try and print from Captivate years ago - 

I create a link to a fillable PDF where the learner can type in their name and print the PDF certificate.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Help resources