Skip to main content
Version: Deprecated Pages

IA Labs PDF Viewer

info

This page refers to the IA Labs PDF Viewer module. This module is only available in Ignition versions 7.7, 7.6, and 7.5. For information on the PDF Viewer component available in versions 7.8 or greater, please see the PDF Viewer page.

The PDF Viewer showing a schematic in a maintenance manual.

Description

Inductive University

PDF Viewer

Watch the video

The PDF Viewer component displays a PDF that exists as a file in some accessible filesystem, or as a URL. Note that this component is simply for viewing existing PDFs. To create dynamic reports, use the Report Viewer component.

This component is typically used in conjunction with the File Explorer component, in order to create a PDF viewing window. See the File Explorer documentation, as well as the File Explorer and PDF Viewer page for instructions on how to put these two components together.

caution

This component is not as high-quality as Adobe Reader. This component can only be guaranteed to correctly display reports generated by the Report Viewer. In practice, it is able to view many PDFs, but it does have trouble with some, especially PDFs created by AutoCAD.

The PDF Viewer component will accept raw bytes of information in addition to a file location. See Example - Storing Files in a Database.

NameData TypeFlags
accessibleContextAccessibleContextbindable
actionMapActionMapbindable
alignmentXfloatbindable
alignmentYfloatbindable
ancestorListenersAncestorListener[]bindable
antialiasbooleanbindable
appContextVisionClientContextbindable
autoscrollsbooleanbindable
backgroundColorbindable
backgroundSetbooleanbindable
baselineResizeBehaviorBaselineResizeBehaviorbindable
borderBorderbindable
boundsRectanglebindable
bytesbyte[]bindable
classClassnone
colorModelColorModelbindable
componentComponentbindable
componentCountintbindable
componentListenersComponentListeners[]bindable
componentOrientationComponentOrientationbindable
componentPopupMenuJPopupMenubindable
componentsComponents[]bindable
containerListenersContainerListeners[]bindable
cursorCursorbindable
cursorCodeintbindable
cursorSetbooleanbindable
dataQualityintbindable
debugGraphicsOptionsintbindable
displayablebooleanbindable
doubleBufferedbooleanbindable
dropTargetDropTargetbindable
dynamicPropsTreeMapbindable
enabledbooleanbindable
filenameStringbindable
focusCycleRootbooleanbindable
focusCycleRootAncestorContainerbindable
focusListenersFocusListener[]bindable
focusOwnerbooleanbindable
focusTraversablebooleanbindable
focusTraversalKeysSetbindable
focusTraversalKeysEnabledbooleanbindable
focusTraversalPolicyFocusTraversalPolicybindable
focusTraversalPolicyProviderbooleanbindable
focusTraversalPolicySetbooleanbindable
focusablebooleanbindable
fontFontbindable
fontSetbooleanbindable
foregroundColorbindable
foregroundSetbooleanbindable
graphicsGraphicsbindable
graphicsConfigurationGraphicsConfigurationbindable
heightintbindable
hierarchyBoundsListenersHierarchyBoundsListener[]bindable
hierarchyListenersHierarchyListener[]bindable
ignoreRepaintbooleanbindable
inheritsPopupMenubooleanbindable
inputContextInputContextbindable
inputMapInputMapbindable
inputMethodListenersInputMethodListener[]bindable
inputMethodRequestsInputMethodRequestsbindable
inputVerifierInputVerifierbindable
insetsInsetsbindable
keyListenersKeyListener[]bindable
layoutLayoutManagerbindable
lightweightbooleanbindable
localeLocalebindable
locationPointbindable
locationOnScreenPointbindable
managingFocusbooleanbindable
maximumSizeDimensionbindable
MaximumSizeSetbooleanbindable
minimumSizeDimensionbindable
minimumSizeSetbooleanbindable
mouseListenersMouseListener[]bindable
mouseMotionListenersMouseMotionListener[]bindable
mousePostionPointbindable
mouseWheelListenersMouseWheelListener[]bindable
nameStringbindable
nextFocusableComponentComponentbindable
opaquebooleanbindable
optimizedDrawingEnabledbooleanbindable
paintingForPrintbooleanbindable
paintingTilebooleanbindable
parentContainerbindable
peerComponentPeerbindable
preferredSizeDimensionbindable
perferredSizeSetbooleanbindable
printingDPIintbindable
printingModeintbindable
propertiesDynamicPropertyDescriptor[]bindable
propertyChangeListenersPropertyChangeListener[]bindable
registeredKeyStrokesKeyStroke[]bindable
requestFocusEnabledbooleanbindable
retainPageOnReloadbooleanbindable
rootPaneJRootPanebindable
showingbooleanbindable
sizeDimensionbindable
stylesDatasetbindable
toolTipTextStringbindable
toolkitToolkitbindable
topLevelAncestorContainerbindable
transferHandlerTransferHandlerbindable
treeLockObjectbindable
validbooleanbindable
validateRootbooleanbindable
verifyInputWhenFocusTargetverifyInputWhenFocusTargetbindable
vetoableChangeListenersVetoableChangeListener[]bindable
visiblebooleanbindable
visibleRectRectanglebindable
widthintbindable
xintbindable
yintbindable
zoomFactorfloatbindable
UIPanelUIbindable
UIClassIDStringbindable

Scripting

Scripting Functions

.loadPDFBytes(bytes, name)

  • Description

    • This function will pass in the bytes of a PDF and load them into the PDF Viewer component. Please see Storing Files in a Database for more details
  • Parameters

    • string bytes - The bytes of the PDF to be displayed on the component.

    • string name - The name of the PDF.

  • Return

    • Nothing
  • Scope

    • Client

.print(useDialog)

Since 7.8.2

  • Description

    • This function will print the PDF.
  • Parameters

    • boolean- If true, shows the user a print dialog. Default is true [optional]
  • Return

    • Nothing
  • Scope

    • Client

.setZoomFactor(zoomFactor)

Since 7.8.2

  • Description

    • This function will set the current zoom level of the PDF, adjusted to stay within the minimum / maximum zoom range. Will zoom in on center of page.
  • Parameters

    • float- Zoom factor to use. 1.0 is no zoom.
  • Return

    • Nothing
  • Scope

    • Client

Extension Functions

This component does not have scripting functions associated with it.

Event Handlers

mouse

  • mouseClicked

    • This event signifies a mouse click on the source component. A mouse click the combination of a mouse press and a mouse release, both of which must have occurred over the source component. Note that this event fires after the pressed and released events have fired.
  • mouseEntered

    • This event fires when the mouse enters the space over the source component.
  • mouseExited

    • This event fires when the mouse leaves the space over the source component.
  • mousePressed

    • This event fires when a mouse button is pressed down on the source component.
  • mouseReleased

    • This event fires when a mouse button is released, if that mouse button's press happened over this component.

mouseMotion

  • mouseDragged

    • Fires when the mouse moves over a component after a button has been pushed.
  • mouseMoved

    • Fires when the mouse moves over a component, but no buttons are pushed.

propertyChange

  • propertyChange
    • Fires whenever a bindable property of the source component changes. This works for standard and custom (dynamic) properties.