HTML Executable Script Editor

Applies to HTML Viewer, IE Browser publications.

The Script Editor is the main place where you edit HEScript scripts.

imgYou can create, remove, import and export scripts with the Script Manager.

imgTo edit a script, just select it in the Script Manager and click Edit. You can also directly double-click on the desired script.

Note that the script editor is also automatically displayed when you import a script.

imgThe script editor looks like this:

img

The script appears in the main edit box.

Description of the behavior

imgThe script editor automatically highlights the syntax. Pascal keywords are in bold, comments in italic.

imgJust make your modifications to the script. Then to ensure there is no error, click Check in the toolbar.

The Check command actually pre-compiles the script in order to ensure there is no syntax error. Thus you can easily find errors:

  • if the script does not contain any error, you get this answer: "Script successfully compiled".

  • otherwise you will receive an error. The error reason and location in source code are given:

    img

    And the line containing the error is marked with red:

    img

    Fix the problem (here you just add a semicolon ";" after OnPageLoaded.
    Press Check again and the red color will disappear.

imgWhen your modifications are finished, you can save the script by clicking Save. Before the script is saved, it is first pre-compiled (as if you clicked Check) and only if it does not contain any syntax error, the editor is closed and the script is saved. If an error is found, the script editor will not close! If you want to close the editor without saving, click Discard.

imgOnly error-free scripts can be saved to the project: that's why scripts are first pre-compiled when you click Save or when scripts are imported. This is for security: since scripts are definitively compiled and linked during the publication's compilation, it is better that they are already syntax-error-free (at least).

imgThe Help button lets you access to these help topics.

img

The fact that a script is syntax-error-free does not guarantee that it will perfectly work! You must always test your publications and see that your scripts work fine!

img Introduction to Scripting

img Using the Script Manager

img Script Function Reference


About

This is the online documentation of HTML Executable.

About HTML Executable

HTML Executable is a versatile HTML compiler and ebook compiler: it lets you create secure ebooks and desktop applications with your websites, HTML or PDF documents.

You can easily create attractive ebooks, full-featured HTML applications (RIA) and software, digital publications from your websites, PDF files and HTML documents for online or offline distribution.

Learn more - Free Trial