Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > Sample Code
  New Posts New Posts RSS Feed - Example - AutoIt - Debenu PDF Viewer SDK
  FAQ FAQ  Forum Search   Register Register  Login Login

Example - AutoIt - Debenu PDF Viewer SDK

 Post Reply Post Reply
Author
Message
mLipok View Drop Down
Senior Member
Senior Member
Avatar

Joined: 23 Apr 14
Location: Poland, Zabrze
Status: Offline
Points: 453
Post Options Post Options   Thanks (0) Thanks(0)   Quote mLipok Quote  Post ReplyReply Direct Link To This Post Topic: Example - AutoIt - Debenu PDF Viewer SDK
    Posted: 05 Jun 14 at 12:38PM
AutoIt Example for Debenu PDF Viewer SDK:
{this is very similar to VisualBasic so I think it is useful}

#Region QuickPDF Include
#include <MsgBoxConstants.au3>
#include <FileConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
#include <String.au3>
#include <File.au3>
#include <WinAPIFiles.au3>
#EndRegion QuickPDF Include

Example(FileOpenDialog('Select PDF File','c:\','PDF File (*.pdf)'))

Func Example($sPDF_FileFullPath)

; Create ActivX object
Local $oQPV = ObjCreate('DPVACTIVEX.Viewer')
$oQPV.LibraryPath = @ScriptDir & '\DebenuPDFLibraryDLL1014.dll'
$oQPV.RendererPath = @ScriptDir & '\DebenuPDFRendererDLL1014.dll'
$oQPV.LicenseKey = 'ENTER YOUR KEY HERE'
$oQPV.ScrollbarsEnabled = True
$oQPV.ToolbarEnabled = True
$oQPV.OpenFile($sPDF_FileFullPath)
$oQPV.SetZoom(1)
$oQPV.GotoPage(1)

; Create a simple GUI for our output
GUICreate("Embedded Web control Test", 800, 600, (@DesktopWidth - 800) / 2, (@DesktopHeight - 600) / 2, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS, $WS_CLIPCHILDREN))
GUICtrlCreateObj($oQPV, 10, 10, 780, 500)
$oQPV.ZoomFitPage()
Local $idButton_Back = GUICtrlCreateButton("Back", 10, 520, 100, 30)
Local $idButton_Forward = GUICtrlCreateButton("Forward", 120, 520, 100, 30)
Local $idButton_Home = GUICtrlCreateButton("Home", 230, 520, 100, 30)

GUISetState(@SW_SHOW) ;Show GUI

; Loop until the user exits.
Local $iMsg
While 1
$iMsg = GUIGetMsg()

Select
Case $iMsg = $GUI_EVENT_CLOSE
ExitLoop
Case $iMsg = $idButton_Back
$oQPV.PrevPage()
Case $iMsg = $idButton_Forward
$oQPV.NextPage()
Case $iMsg = $idButton_Home
$oQPV.GotoPage(1)

EndSelect

WEnd
$oQPV = '' ; CleanUp

GUIDelete()
EndFunc   ;==>Example

Cheers
mLipok




Edited by mLipok - 15 Sep 14 at 9:28AM
Here you can find description how to test my examples:
http://www.quickpdf.org/forum/forum_posts.asp?TID=2932&PID=12600&title=drawcapturedpagematrix-matrix-howto#12600
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store