Login
Products
Sales
Support
Downloads
About
Home
»
Technical Support
»
Elevate Web Builder Technical Support
»
Support Forums
»
Elevate Web Builder General
»
View Thread
View Thread
The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
HOWTO: External Interface to Namespace ?
Tue, May 24 2016 9:10 PM
Permanent Link
Trinione
Hi:
I know how to access regular functions, however I cannot figure out how to access Namespaces.
Any help would be appreciated.
--------------------------------------------
Filename: MyExternalJS.js
--------------------------------------------
function MyApplication () {
this.sum = function(a, b) {
return a + b;
};
this.reset = function() {
this.var1 = 0;
this.var2 = 0;
return this.var1 + this.var2;
}
};
var myApp = new MyApplication();
myApp.var1 = 4;
myApp.var2 = 6;
console.log(myApp.sum(myApp.var1, myApp.var2));
console.log(myApp.reset());
console.log(myApp.sum(myApp.var1, myApp.var2));
Wed, May 25 2016 12:40 AM
Permanent Link
Trinione
Never mind.
Other posts in the forum explain it sufficiently.