EaxCategoryView.loadFile

Syntax

loadFile(fileName: String, callback: PP.Delegate, argumentss: Object);

Parameters

fileName. Path of loaded script.

callback. Callback function executed after a JavaScript script is loaded.

argumentss. Loading arguments.

Description

The loadFile method loads JavaScript script file.

Example

Executing the example requires that the HTML page contains the ExpressBox component named expressBox (see Example of Creating the ExpressBox Component). Load a JavaScript file named PP.TagCloud.js:

// Get view of the Table tab
var category = expressBox.getRibbonView().getTableCategory();
// Load file
category.loadFile("../build/PP.TagCloud.js", function(sender, args) {
    console.log("File is successfully loaded");
});

After loading of the script file the console displays a message about successful complete operation:

File is successfully loaded

 

Check if the PP.Ui.TagCloud class exists:

// Check if the PP.Ui.TagCloud class exists
if (PP.Ui.TagCloud) {
    console.log("Class exists");
} else {
    console.log("Class does not exist");
}

As a result the console displays class existence check result:

Class exists

See also:

EaxCategoryView