January 25, 2024
Captivate 9: Interactions
Comments
(2)
January 25, 2024
Captivate 9: Interactions
(2)

I’m fairly new to this product, but I’m wondering if there’s a way to ensure users scroll to the bottom of a PDF BEFORE they can proceed to the next slide.

I’ve tried everything but I’m not sure if it can even be done here, if that’s a PDF edit or even beyond that. What little I could find in research mentioned a Javascript, but again, I’m not sure if that’s definite or not.

I appreciate ANY help or guidance.

2 Comments
2024-01-29 09:50:47
2024-01-29 09:50:47

Captivate 9 is no longer supported. Are you sure about the version number? Check the full  number under Help, About Captivate.

Is the pdf embedded in the published output?  Or is it published on a webserver and opened by pointing to the URL? That is an important difference.

 

Like
2024-01-29 09:32:48
2024-01-29 09:32:48

x-5 lgx-1 xlx-5 md:max-w-3xl lg:max-w-[40rem] xl:max-w-[48rem] group final-completion”>

rose-invert light”>

  1. Open your PDF in Adobe Acrobat:
    • Ensure you have the full version of Adobe Acrobat, as the free Adobe Reader might not support advanced JavaScript features.
  2. Access the JavaScript Console:
    • Go to View -> Tools -> JavaScript -> Console.
  3. Write the JavaScript Code:
    • Use JavaScript to check if the user has scrolled to the bottom. If not, prevent them from proceeding.

    javascriptCopy code
    var isScrolledToBottom = function() {
    var pdf = this;
    var pageHeight = pdf.getPageHeight();
    var scrollPosition = pdf.getViewScroll();
    var windowHeight = pdf.viewHeight;

    return (pageHeight – scrollPosition – windowHeight) < 10; // Adjust the threshold as needed
    };

    var requireScrollToBottom = function() {
    if (!isScrolledToBottom()) {
    app.alert(“Please scroll to the bottom before proceeding.”, 3); // 3 is the warning icon
    this.pageNum–; // Go back to the current page
    }
    };

    this.pageNum = 1; // Starting page number
    this.setAction(“PageClose”, requireScrollToBottom);

  4. Save the Changes:
    • Save the PDF with the embedded JavaScript.

Please note that not all PDF viewers support JavaScript, and users may need to have JavaScript enabled in their PDF viewer for this functionality to work.

Vaishnavi Krishna Brundavan

Like
Add Comment