Status: Validated

Compilation with Desktop Studio


Desktop Studio automatically compiles the project before running it.
The project can also be manually compiled by using the button in the Debugger Toolbar.

During compilation, the following checks are performed:

  • Application/Page/Items declaration completion
    Verify application / page / item recognition criteria.
    Note that only criterion completion is checked during compilation. Recognition is performed at runtime.
  • Javascript code compilation
    A full code compile is performed, including:
    • Javascript syntax,
    • Variable control,
    • Function calls,
    • and so on
  • XML code compilation
    The XML code is checked merely for conformity to the XsdStudio_V3.xsd XSD file.
    Note that coherence checks are not performed.:
    • Application / Page / Item name,
    • XPath usage,
    • and so on

The results of compilation are displayed in the Error List Tool Window.

Note:

  • Compilation errors prevent the project from being executed. This can be bypassed by checking the 'Allow Run with Compile errors' setting in the 'Debugger Settings' (see Debugger Settings),
  • Some Compilation errors can be qualified in Compilation warnings using the CompilerFilters entry in the SDK.xml file (see Studio Configuration).


Once compilation is completed, Desktop Studio generates project output in the 'bin' directory (see Structure of a Project).
The following operations are performed:

PSC file Generation

  • Collects all the Pscp and Pscr files of the various declared applications and places them in a single compiled Psc file.
    The compiled file is generated in the 'bin' directory.

Collection of Project Files:

  • Collects all files stored in the 'local' directory of the project and copies them to the 'bin' directory,
  • 'local' subdirectories are also collected and copied to the same 'bin' subdirectory tree.

Collection of SDK Files:

  • Collects all SDK files referenced by the project and copies them to the same 'bin' relative subdirectory tree.
    For example: <SCRIPT Src=“%sdk%\lib\utils\fso.js” /> will copy the fso.js SDK file to the bin\lib\utils subdirectory.
  • The destination subdirectory can be modified using the Dest attribute of the SCRIPT node.
    For example: <SCRIPT Src=“%sdk%\lib\utils\fso.js” Dest=“test” /> will copy the fso.js SDK file to the bin\test subdirectory.

Collection of Resource Files:

  • Collects all resource files and directories referenced by the project (see Resource Files Management) and copies them to the 'bin' directory.
    Subdirectories are also collected and copied to the same 'bin' subdirectory tree
    For example: <RESOURCE Src=“%sdk%\templates\resources\bmp\” /> will copy all the %sdk%\templates\resources\bmp files and subdirectories to the bin directory.
  • The destination subdirectory can be changed using the Dest attribute of the RESOURCE node
    For example: <RESOURCE Src=“%sdk%\templates\resources\bmp\” Dest=“bmp” /> will copy the resource files to the bin\bmp subdirectory.


Error List Tool Window The Error List tool window in the Editor Perspective displays the compilation results.
Lines are grouped by script file or XML block.

Each line can be:

  • an error,
  • a warning.

By double-clicking a line, you can navigate to the corresponding line in the script file or the XML block.


Output Tool Window The Output tool window in the Editor Perspective displays the output generated by Desktop Studio:

  • Compilation output,
  • Export output,
  • Project running output.

This output is for information only.