Jump to content

Scrolling PDF KIOSK


Recommended Posts

The example scripts forum wouldn't allow me to post so I'll try here.

A SCROLLING PDF KIOSK

Adobe Reader can auto scroll but not loop a pdf.

AutoIT to the rescue!

Run("C:\Program Files\Adobe\Reader 8.0\Reader\AcroRd32.exe /A scrollbar=0&navpanes=0&statusbar=0&messages=0&toolbar=0&zoom=130 c:\docs\newsletter.pdf")

;wait for this window title to be active

WinWaitActive("newsletter.pdf - Adobe Reader")

;Hide the menus

Send("{F9}")

While 1 = 1

;Return to top of file

Send("{HOME}")

;Begin scroll

Send("^+H")

;Speed of scroll is slow 2

Send("2")

;Wait 3 mins for scroll to finish

Sleep(180000)

;End scrolling if it hasn't already

Send("^+H")

WEnd

Link to comment
Share on other sites

The example scripts forum wouldn't allow me to post so I'll try here.

A SCROLLING PDF KIOSK

Adobe Reader can auto scroll but not loop a pdf.

AutoIT to the rescue!

Run("C:\Program Files\Adobe\Reader 8.0\Reader\AcroRd32.exe /A scrollbar=0&navpanes=0&statusbar=0&messages=0&toolbar=0&zoom=130 c:\docs\newsletter.pdf")

;wait for this window title to be active

WinWaitActive("newsletter.pdf - Adobe Reader")

;Hide the menus

Send("{F9}")

While 1 = 1

;Return to top of file

Send("{HOME}")

;Begin scroll

Send("^+H")

;Speed of scroll is slow 2

Send("2")

;Wait 3 mins for scroll to finish

Sleep(180000)

;End scrolling if it hasn't already

Send("^+H")

WEnd

Welcome to the AutoIt forums moot. :D

You can only post in the example forums when you have already made a minimum number of posts. This prevents new people posting there in error.

Good to see you worked out how to scroll your pdf, especially since you did it without support from here.

It would be more versatile if you had some way of knowing that you have reached the end of the document and some way to make sure that the end has not already been reached before you send a second ^H or it will start scrolling backwards which is difficult to read unless you have a fantastic memory!

An option for full screen view would be nice but unfortunately that makes the scrolling a bit fast.

Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Link to comment
Share on other sites

Welcome to the AutoIt forums moot. :D

You can only post in the example forums when you have already made a minimum number of posts. This prevents new people posting there in error.

Good to see you worked out how to scroll your pdf, especially since you did it without support from here.

It would be more versatile if you had some way of knowing that you have reached the end of the document and some way to make sure that the end has not already been reached before you send a second ^H or it will start scrolling backwards which is difficult to read unless you have a fantastic memory!

An option for full screen view would be nice but unfortunately that makes the scrolling a bit fast.

The timer problem is overcome by adding a blank page to the end of PDF and checking for that page number. If it is the current page then go to page 1. Code suggestions welcome.

The ZOOM level is set in the parameters of line 1 after acroread.exe.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...