Developer Guide (API Reference) > Flash Viewer > Methods/Functions |
Method |
Details |
alert |
Show an alert box in the viewer with a message. |
assignHighlightColor |
Assign a color through javascript for text selection. |
loadHighlights |
Passing Highlights XML to Viewer through JavaScript. |
clearHighlights |
Clear loaded highlights XML. |
gotoPage(pageNumber ) |
Load a particular page in the viewer. |
getMarksXml | Retrieves the XML string that describes all annotations in the document. |
loadAnnotationsFile |
Takes a file name and loads the XML stream from the file. For example: var app = document.getElementById("ViewerEnterpriseAnnotation"); This will cause the Flash viewer to search for and open an annotations file called "annotations.xml" in the root of the Markups folder. |
alert(“text to be shown in alert box”)
Example |
Copy Code
|
---|---|
<a href=javascript: ViewerEnterprise.alert(“text to be shown in alert box”)>Show Alert</a>
|
Method |
Details |
alert |
Show an alert box in the viewer with a message |
assignHighlightColor |
Assign a color through javascript for text selection. |
loadHighlights |
Passing Highlights XML to Viewer through JavaScript. |
clearHighlights |
Clear loaded highlights XML. |
loadAnnotations |
Passing Annotations XML to Viewer through JavaScript. |
removeAnnotations |
Clear loaded annotations XML. |
saveAnnotations |
Save loaded annotation Save loaded annotation. |
getMarksXml | Retrieves the XML string that describes all annotations in the document. |
alert(“text to be shown in alert box”)
Example |
Copy Code
|
---|---|
<a href=javascript: ViewerEnterprise.alert(“text to be shown in alert box”)>Show Alert</a>
|
assignHighlightColor(hexcode of color)
Example |
Copy Code
|
---|---|
<a href=javascript: ViewerEnterprise.assignHighlightColor (0xFFFF00)>Set Color</a> |
loadHighlights(XML_TO_ADD)
clearHighlights()
Example |
Copy Code
|
---|---|
ViewerEnterprise.loadHighlights( "<root><actions><action type='addHighlight'> <highlight documentname='PowerCfg.odt' id='AE40B90F8A971CF262C3090970DEC151' userid='' tooltip='' mode='ByText' occurance='1' page='0' allowDelete='true' color='16776960' start='0' end='0' annotation='0'><![CDATA[paper]]></highlight></action></actions></root>" );
ViewerEnterprise.clearHighlights();
|