Overview
This document covers most of the functions made available by the Host application. String Arguments The string arguments for any of the functions below should be UTF-8 encoded.JavaScript helpers
Simple javascript helpers.extend
Version: 5.1.10 Equivalent to jQuery extend function.extractFromSkinFile
Extracts a file from the skin to disk. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
hashFile
Hashes a file using a specific algorithm and returns the digest. Version: 7.1 Arguments:
Return Value:
Complete callback is always called and passes the digest and the successful result to the complete callback.
Changes:
- 7.0 - Removed MD2 and MD4 hash algorithms
isNull
Checks to see if a value is null or undefined Version: 3.6 Arguments:
Return Value:
True if null, undefined or a blank jQuery selector, false otherwise.
Example:
readJSONFromFile
Reads a text from a file and parse it into JSON object. Version: 5.1.7 Arguments:
Return Value:
Complete callback is always called and if successful passes the JSON object to the complete callback, otherwise passes null.
readJSONFromSkinFile
Reads a text from a file in the skin and parse it into JSON object. Version: 5.1.10 Arguments:
Return Value:
Complete callback is always called and if successful passes the JSON object to the complete callback, otherwise passes null.
readTextFromFile
Read text from a file. Version: 5.1.7 Arguments:
Complete callback is always called and if successful passes the string to the complete callback, otherwise passes null.
readTextFromSkinFile
Read text file from the skin. Version: 5.1.10 Arguments:
Complete callback is always called and if successful passes the string to the complete callback, otherwise passes null.
thisIs
Checks if a bit value is on. Version: 3.6 Arguments:
Return Value:
True if the bit is set, otherwise false.
Example:
thisIsNot
Checks if a bit value is off. Version: 3.6 Arguments:
Return Value:
True if the bit is not set, otherwise false.
Example:
turnOff
Turns a bit value off. Version: 5.1 Arguments:
Return Value:
Returns the value with the bit turned off.
Example:
turnOn
Turns a bit value on. Version: 5.1 Arguments:
Return Value:
Returns the value with the bit turned on.
Example:
writeJSONToFile
Writes JSON to a file. Version: 5.1.7 Arguments:
Return Value:
True if successful, false otherwise.
Changes in 5.2:
- Added spaces argument
writeTextToFile
Writes text to a file. Version: 5.1.7 Arguments:
Return Value:
True if successful, false otherwise.
Analytics
Analytics functions.extend
Sends additional data along with all analytics events. Version: 5.1.10 Arguments:
Example:
sendEvent
Queues an analytics event for sending. Analytics events are queued and sent on an interval defined in the application configuration’s analytics.sendInterval property. If there are events left to be sent when the application shuts down they will be sent before the application closes. Version: 5.1.8 Arguments:
Return Value:
True if successful, false otherwise.
Example:
setEnabled
Sets whether or not analytics is enabled. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
Notes:
- To disable sending of analytics this should be called before any send interval occurs.
setEndpoint
Sets the endpoint for sending analytics events. Version: 7.2.46 Arguments:
Return Value:
True if successful, false otherwise.
setKey
Sets analytics api key. Version: 7.2.29 Arguments:
Return Value:
True if successful, false otherwise.
App (SkinApp)
High level host application functions.closeAllWindows
Closes all the application windows. Version: 3.6 Return Value: True if successful, false otherwise.contentExists
Gets whether or not a content exists in the app bundle. Version: 6.1 Arguments:
Return Value:
True if content exists, false otherwise.
Example:
expandString
Same as workflowApp.expandString except that {contentUrl} macro is expected using the —devserver argument first. This is useful during development in instances where you want to get the url to the devserver if it is available, but to otherwise fallback to the internal web server when —devserver is not available. Version: 6.1getCountry
Gets the locale country set for the application in ISO 3166 format. Version: 3.6getDataStore
Gets the base-64 encoded authenticated datastore for the current application. Version: 6.1.0.96 Example:getLanguage
Gets the locale language in set for the application in ISO 639 format. Version: 3.6getRemoveLocalStorage
Gets whether or not the flag to remove the local storage on shutdown is set. Version: 3.6isAttached
Gets whether or not a skin is attached to the current executable. Version: 6.1.0.96.isMainWindow
Gets whether or not the skin window is the main window. Version: 5.2.033. Arguments:
Return Value:
Returns true if the window is the main window, false otherwise.
localizeString
Localizes a string in the current language. It is not recommended to call this function for each locale string as it can impact performance negatively. Instead independently load the localization files in JavaScript using XMLHttpRequest. Version: 3.6 Arguments:
Return Value:
Returns the localized string, otherwise it returns stringId.
openWindow
Opens a new top level skin window. Version: 3.6 Arguments:
Return Value:
Returns the instance id of the new window if successful, null otherwise.
setCountry
Sets the locale country for the application in ISO 3166 format. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setLanguage
Sets the locale language for the application in ISO 639 format. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setRemoveLocalStorage
Sets whether or not to remove the local storage directory on shutdown. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
App (WorkflowApp)
Lower-level host application functions.addMacro
Adds a macro to the application’s macro table. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
Example:
convertFromEntitizedString
Converts an a string with HTML entitized Unicode characters into their UTF-8 equivalent. Version: 3.4 Arguments:
Return Value:
Returns an UTF-8 string.
convertToEntitizedString
Converts a string containing Unicode characters that are UTF-8 encoded into their HTML entitized equivalent. Version: 3.4 Arguments:
Return Value:
Returns an HTML entitized string.
crash
Crashes the application. Used for testing crash reporting. Version: 3.6debugPrint
Prints a line to the debug log. Version: 3.6 Arguments:
Example:
expandString
Expands the string with the current applications macros. Version: 3.6 Arguments:
Return Value:
Returns the expanded string.
Changes:
- 6.1 - Added defaultValue argument
- 6.1 - Added support for objects and lists
getCommandFieldCount
Gets the number of arguments in a command line. Version: 6.1 Example:getCommandField
Gets the value for a command field by its index. Version: 6.1 Example:getCommandFieldByName
Gets the value for a command field by its name (case-insensitive). Version: 3.6 Example:- This function is NOT intended for use with command line (flags) parameters that contain no value.
getCommandLine
Gets the command line string for the application. Version: 3.6getConfig
Retrieves a config setting given its key. Version: 5.1 Arguments:
Return Value:
Returns the value for the configuration key.
Example:
getCurrentTime
Gets the seconds.milliseconds since computer started. Version: 3.6getDebugFilename
Gets the path of the debug log. Version: 3.6getDebugFlags
Gets the debug flags set. Version: 3.6getExitCode
Gets the exit code set for the application when it exits. Version: 5.1getPreventSystemShutdown
Gets whether or not to prevent system shutdown while tasks are active. Not applicable if cef.enabled set to true. Version: 5.2getRestart
Gets whether or not the flag to restart is set. Version: 3.6 (previously skinApp.getRestart )getRestartArguments
Gets the command line arguments string used for restarting the application. Version: 3.6 (previously getRestartCommandLine )getRestartElevated
Gets whether or not the flag to restart elevated is set. Version: 3.6 (previously skinApp.getRestartElevated )getRestartPath
Gets the path to the executable to launch when restarting. Version: 6.1 (previously part of getRestartCommandLine )getRunningTime
Gets the seconds.milliseconds the application has been running. Version: 3.6getSecurityEnabled
Gets whether or security is enabled. Version: 3.6getStartTime
Gets the seconds.milliseconds since the computer started at application start. Version: 3.6implode
Sets a flag to self-delete the executable after exiting. Version: 3.6isCommandFieldSet
Checks to see if a command flag is set on the command line. Version: 3.6 Arguments:
Return Value:
True if the command flag if it is set, false otherwise.
Notes:
- This function is ONLY intended for use with command line (flags) parameters that contain no value.
isElevated
Gets whether or not the application is elevated. Version: 5.1jwsVerifyCertStore
Verifies a JSON web signature that has been signed with a certificate. Version: 6.1 (jwsVerifyX509 in 5.2) Arguments:
Return Value:
True if verified successfully, false otherwise.
jwsVerifyKey
Verifies a JSON web signature that has been signed with a secret key. Version: 5.2 Arguments:
Return Value:
True if verified successfully, false otherwise.
jwsVerifyKeyStore
Verifies a JSON web signature against a key in the key store. Version: 6.1 Arguments:
Return Value:
True if verified successfully, false otherwise.
loadInterop
Loads an interop. Version: 3.6, 5.1.9 Arguments:
Return Value:
Fires a notification when complete. The name value is sent to the notification.
setExitCode
Sets the exit code for the application when it exits. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
setPreventSystemShutdown
Sets whether or not to prevent system shutdown while tasks are active. Version: 5.2setRestart
Sets whether or not to restart the application after shutting down. Version: 3.6 (previously skinApp.setRestart ) Arguments:
Return Value:
True if successful, false otherwise.
setRestartArguments
Sets the command line arguments string for restarting the application. Version: 6.1, 3.6 (previously setRestartCommandLine or setCommandLine ) Arguments:
Return Value:
True if successful, false otherwise.
setRestartElevated
Sets whether or not to restarted the application elevated upon after shutting down. Version: 3.6 (previously skinApp.setRestartElevated ) Arguments:
Return Value:
True if successful, false otherwise.
setRestartPath
Sets the path to the executable to use when restarting the application. Version: 6.1 (previously part of setRestartCommandLine ) Arguments:
Return Value:
True if successful, false otherwise.
unloadInterop
Unloads an interop. Version: 3.6, 5.1.9 Arguments:
Return Value:
Fires a notification when complete. The name value is sent to the notification.
AppDebugFlags (WorkflowAppDebugFlags)
Debug flags enumeration.nameFromId
Returns a string representing the specified enumeration value. Arguments:AppNotificationDock (WorkflowAppNotificationDock)
Notification dock flags enumeration.nameFromId
Returns a string representing the specified enumeration value. Arguments:DirectorySize
Calculates directory allocated size on the disk.createDirectorySize
Creates a new DirectorySize object. Version: 7.0 Example:getPath
Gets the directory path. Version: 7.0release
Releases the instance. Version: 7.0setPath
Sets the directory path. Version: 7.0 Arguments:
Return Value:
True if successful, false otherwise.
start
Starts calculating the size. Version: 7.0stop
Interrupts calculating the size. Version: 7.0FileSystem
File system functions.directoryCreate
Creates a directory. Version: 5.1, 3.6 as platform.directoryCreate Arguments:
Return Value:
Returns 0 if the path was created, OS error code otherwise.
Example:
directoryErase
Removes a directory. Version: 5.1, 3.6 as platform.directoryErase Arguments:
Return Value:
Returns 0 if the path was removed or doesn’t exist, OS error code otherwise.
Warning:
- This function is a blocking call and long running operations can block the UI.
- Alternatively, use the directoryErase task.
directoryExists
Checks if a directory exists. Version: 5.1, 3.6 as platform.directoryExists Arguments:
Return Value:
True if the path exists and it is a directory or drive, false otherwise.
Example:
directoryGetSize
Gets the size of the directory content allocated on the disk file system. Version: 6.1 Arguments:
Return Value:
True if the path is valid directory and there is no an active directoryGetSize call, false otherwise.
Example:
directoryIsEmpty
Checks to see if a directory is empty. Version: 5.2 Arguments:
Return Value:
True if the path is empty, false otherwise.
Example:
fileCopy
Copies a file, overwriting if necessary. Version: 5.1, 3.6 as platform.fileCopy Arguments:
Return Value:
True if the file was successfully copied, false otherwise.
Notes:
- This function is a blocking call and long running operations can block the UI.
- Alternatively, use the fileCopy task.
fileErase
Removes a file. Version: 5.1, 3.6 as platform.fileErase Arguments:
Return Value:
Returns 0 if the path was removed, OS error code otherwise.
fileExists
Checks if a file exists. Version: 5.1, 3.6 as platform.fileExists Arguments:
Return Value:
True if the path exists, false otherwise.
fileGetSize
Gets the size of the file Version: 5.2 Arguments:
Return Value:
Size of the file in bytes.
Example:
fileRename
Renames a file from one location to another. Version: 7.2.15 Arguments:
Return Value:
True if the file was successfully renamed, false otherwise.
Notes:
- This function is a blocking call and long running operations can block the UI.
getCreationTime
Gets the creation time for a file or directory. Version: 5.1 Arguments:
Return Value:
Returns the unix timestamp of the file or directory’s creation time if successful, otherwise it returns 0.
Example:
getFreeDiskSpace
Gets the number of free bytes on disk. Version: 5.1, 3.6 as platform.getFreeDiskSpace Arguments:
Example:
getModifiedTime
Gets the modified time for a file or directory. Version: 5.1 Arguments:
Return Value:
Returns the unix timestamp of the file or directory’s modified time if successful, otherwise it returns 0.
Example:
pathConvertFromUrl
Parses a path from a file:// url. Version: 5.2 Arguments:
Return Value:
Returns the path, empty string otherwise.
pathConvertToUrl
Parses a path to a file:// url. Version: 5.2 Arguments:
Return Value:
Returns the url, empty string otherwise.
pathFixSlash
Resolves dots, fixes slashes, and adds or removes a trailing slash. Version: 5.2 Arguments:
Return Value:
Returns fixed path.
Example:
pathParseDirectory
Parses the directory from a path. Version: 5.2 Arguments:
Return Value:
Returns the directory parsed, empty string otherwise.
pathParseExtension
Parses the extension from a path. Version: 5.2 Arguments:
Return Value:
Returns the extension parsed, empty string otherwise.
pathParseName
Parses the filename from a path. Version: 5.2 Arguments:
Return Value:
Returns the filename parsed, empty string otherwise.
pathParseNameWithoutExtension
Parses the filename from a path without its extension. Version: 5.2 Arguments:
Return Value:
Returns the filename without extension parsed, empty string otherwise.
pathResolve
Converts a tilde path into a full path and fixes slashes without modifying the trailing slash. Version: 5.2 Arguments:
Return Value:
Returns resolved path.
Example:
setGroup
Ensures that a file is writable by all given user types. Version: 5.1 Arguments:
Return Value:
True on success and false on failure.
HashFile
The HashFile class is used to asynchronous hash a binary file.getBytesLeft
Gets the number of bytes left to hash in the file. Version: 7.1getDigest
Gets the hash digest when hashing is complete. Version: 7.1getFileSize
Gets the total size of the file being hashed. Version: 7.1getPath
Gets the path to the file to hash. Version: 7.1setAlgorithm
Name of the hash algorithm. Version: 7.1 Arguments:
Return Value:
True if successful, false otherwise.
Changes:
- 7.0 - Removed MD2 and MD4 hash algorithms
setPath
Sets the path to the file to hash. Version: 7.1 Arguments:
Return Value:
True if successful, false otherwise.
start
Starts hashing. Version: 7.1HttpRequest
The HttpRequest class is used by the JavaScript HttpRequestXhr class which functions as an XHR replacement.abort
Aborts the request. Version: 3.6appendPostData
Appends data to post body. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
clearPostData
Clears the post body data. Version: 3.6createHttpRequest
Creates an HTTP request object. Version: 5.1 Example: Recommend use of the HttpRequestXhr in JavaScript. jQuery is setup to redirect requests to HttpRequestXhr. Include ‘httpRequestXhr’ module in AngularJS.getAllowAuthentication
Gets whether or not the connection should support proxy, or HTTP authentication. Version: 5.2getAllowProxy
Gets whether or not the connection should go through a proxy. Version: 5.2getBody
Gets the response body buffer. Version: 3.6 Arguments:
Return Value:
Base-64 encoded buffer of the response starting at offset with length. If the offset is invalid, the function will return null.
getBodySize
Gets the response body size of the request. Version: 3.6getCleanup
Gets whether or not it should delete the file when the object is released. Version: 3.6getContentLength
Gets the content length of the response. Version: 3.6getFileName
Gets the file name where the url is saved (empty to save to buffer). Version: 3.6getFilePosition
Gets the current position in the file it is saving to. Version: 3.6getHeader
Gets the request header buffer. Version: 3.6 Return Value: Gets the request headers.getHeaderValue
Gets the value of a request header. Version: 3.6 Arguments:
Return Value:
Returns the value of the header.
getHttpCode
Gets the HTTP code that was returned in the response. Version: 3.6getLimitBodySize
Gets the maximum body size for the request. Version: 3.6getLimitRedirects
Get the maximum amount of allowed HTTP redirects. 0 means redirects are disallowed. Version: 7.2getPartialFileName
Gets the partial file name where the url is saved Version: 5.2getResponseHeader
Gets the response header buffer. Version: 5.2 Gets the response headers.getResponseHeaderValue
Gets the value of a response header. Version: 5.2 Arguments:
Return Value:
Returns the value of the response header.
getTimeout
Gets the seconds to wait for I/O before timeout. Version: 3.6getType
Gets the type of HTTP request. Version: 3.6getUrl
Gets the url for the request. Version: 3.6getUseCache
Gets whether or not to use caching. Version: 3.6hasResponseHeader
Checks if a value exists in the response header. Version: 5.2, formerly as headerExists Arguments:
Return Value:
True if header exists, false otherwise.
release
Release the instance. Version: 3.6reset
Resets the request. Version: 3.6setAllowAuthentication
Sets whether or not the connection should support proxy, or HTTP authentication. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
setAllowProxy
Sets whether or not the connection should go through a proxy. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
setByteRange
Sets the byte range for the request. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setCleanup
Sets whether or not it should delete the file when the object is released. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setFileName
Sets the file name where the url is saved (empty to save to buffer). Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setHeaderValue
Sets the value of a request header. Version: 3.6 Arguments:
Notes:
- Header names and values are not evaluated for correctness.
setLimitBodySize
Sets the maximum body size for the request. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setLimitRedirects
Sets the maximum amount of allowed HTTP redirects. 0 disallows redirects. Version: 7.2 Arguments:
Return Value:
True if successful, false otherwise.
setTimeout
Sets the seconds to wait for I/O before timeout. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setType
Sets the type of HTTP request. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setUrl
Sets the url for the request. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setUseCache
Sets whether or not to use caching. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
start
Starts the request. Version: 3.6waitForRequest
Blocking call to wait for request. Not recommended for use. Only implemented for backwards compatibility for some old scripts. Version: 5.1HttpRequestType
HTTP request type enumeration.nameFromId
Returns a string representing the specified enumeration value. Arguments:NotificationCenter
Handles application notifications.addInstanceObserver
Watches for a notification center event on a specific object and fires a function when encountered. Version: 3.6 Arguments:
Return Value:
Returns an observer object which can be released/deleted when the observer is no longer needed.
Example:
addObserver
Watches for a notification center event and fires a function when encountered. Version: 3.6 Arguments:
Return Value:
Returns an observer object which can be released/deleted when the observer is no longer needed.
Example:
fire
Fires a notification center event instantly. The notification event will be fired both in the JavaScript layer and the Interop layer. Version: 3.6 Arguments:
Example:
fireAfterDelay
Fires a notification center event after a certain amount of time has elapsed. The notification event will be fired both in the JavaScript layer and the Interop layer. Version: 3.6 Arguments:
Example:
removeInstanceObserver
Removes an observer from a specific object given its callback. Version: 3.6 Arguments:
Example:
removeObserver
Removes an observer given its callback. Version: 3.6 Arguments:
Example:
Pipe
Represents a system pipe object.createPipe
Creates a new pipe instance. Version: 3.6 Example:getBufferSize
Gets buffer size of the pipe for reading and writing. Version: 3.6getName
Gets the name of the pipe. Optional in 7.0 Version: 3.6getOpenExisting
Gets whether or not it will open an existing pipe. Version: 3.6release
Releases the instance. Version: 3.6setBufferSize
Sets the buffer size of the pipe for reading and writing. Version: 3.6 Arguments:setName
Sets the optional name of the pipe; if empty, the unnamed/anonymous pipe will open Version: 3.6 Arguments:
Return Value:
True if the name was set, false otherwise.
setOpenExisting
Sets whether or not it will open an existing pipe. Version: 3.6 Arguments:
Return Value:
True if the value was set, false otherwise.
start
Opens a pipe for reading and writing. Version: 3.6 Return Value: True if successfully started reading, false otherwise. Pipe reads will be streamed on the Pipe.Read notification.write
Writes to the pipe Version: 3.6 Arguments:
Return Value:
Returns the number of bytes written to the byte.
Example:
Platform
System platform functions.access
Determines if the current process has desired access to the directory. Version: 5.1 Arguments:
Return Value:
If the current process has the specified permissions it returns true, false otherwise.
Example:
authenticateX509
Validates a certificate .DER file on disk. Version: 5.1, 3.6 as platform.authenticateCertificate Arguments:
Return Value:
True if the certificate is valid, false otherwise.
Example:
createShortcut
Creates a virtual shortcut on the system. Version: 3.6 Supported OS:- Windows
- Linux
Return Value:
True if the shortcut was created, false otherwise.
Example:
findProcess
Finds the specified process open on the system. Version: 5.1, 3.6 as platform.isProcessRunning Arguments:
Return Value:
Returns the ID of the process if found. If the process is not found, it returns -1.
Example:
findWindow
Finds the specified window open on the system. Version: 3.6 Arguments:
Notes:
- If both caption and className are specified, it will try to match either field. To match only a specific field, specify an empty string for the other.
getCredential
Gets a credential from the system credential store. Version: 5.2, 5.1 asworkflowApp.getCredential Arguments:
Return Value:
Returns a JSON object if successful, false otherwise:
getCurrentProcessId
Gets the ID for the current process. Version: 7.2.54getDataStore
Gets the base-64 encoded unauthenticated datastore for the current application. Version: 5.2 Example:getFileDataStore
Gets the base-64 encoded datastore for a particular file. Version: 5.2 Example:getModuleDistribution
Gets the DirectGVR deployment name for the current process. See documentation for{moduleDistribution} for possible values.
Version: 7.2.60
getName
Gets the name of the platform. Version: 5.2 Example:getParentProcessId
Gets the parent process id for a process given its process id. Version: 8.0.5 Arguments:
Return Value:
Returns the id of process’ parent if successful.
Example:
getProcessPath
Gets the path for a process given its process id. Version: 5.2 Arguments:
Return Value:
Returns the path to the process if successful, otherwise an empty string.
Example:
getShortName
Gets the short name of the platform. Version: 5.2 Example:getSystemTheme
Gets the name of the current system theme. Version: 6.1 Example:getUserCountry
Gets the current user’s country set on the machine in ISO 3166 format. Version: 5.1 Example:getUserLanguage
Gets the current user’s language set on the machine in ISO 639 format. Version: 5.1 Example:getUserName
Gets the current user’s name. Version: 5.2 Example:getWebCredential
Gets a web credential from the system credential store. Version: 5.2, 5.1 asworkflowApp.getWebCredential Arguments:
Return Value:
Returns a JSON object if successful, false otherwise:
preventSystemSleep
Prevents or allows the system to sleep. Version: 7.2.15 Arguments:
Return Value:
True if successful, false otherwise.
Example:
reboot
Reboots the system. Version: 3.6 Example:removeCredential
Removes a credential from the system credential store. Version: 5.2, 5.1 asworkflowApp.removeCredential Arguments:
Return Value:
True if successful, false otherwise.
removeShortcut
Removes a shortcut from the system. Version: 3.6 Supported OS:- Windows
- Linux
Return Value:
True if the shortcut was removed, false otherwise.
Example:
removeWebCredential
Removes a web credential from the system credential store. Version: 5.2, 5.1 asworkflowApp.removeWebCredential Arguments:
Return Value:
True if successful, false otherwise.
setEnvironmentVariable
Sets a process environment variable. Version: 6.1.0.74 Arguments:
Return Value:
True if successful, false otherwise.
setCredential
Sets a credential in the system credential store. Version: 5.2, 5.1 asworkflowApp.setCredential Arguments:
Return Value:
True if successful, false otherwise.
setWebCredential
Sets a web credential in the system credential store. Version: 5.2, 5.1 asworkflowApp.setWebCredential Arguments:
Return Value:
True if successful, false otherwise.
shellOpen
Runs a system shell command. Version: 3.6 Arguments:
Result:
Run the command specified by path. If you specify a file as the path, the system will open the file with its associated application. If you specify a folder as the path, the system will open up the folder in its file explorer.
Changes in 7.1:
- Added new arguments parameter
terminateProcess
Terminates a process given its ID by sending close messages to the main windows of the process. Version: 7.1 Arguments:
Return Value:
True if successful, false otherwise.
terminateProcessForcefully
Terminates a process given its ID by killing it. Version: 7.1 Arguments:
Return Value:
True if successful, false otherwise.
timeToRFC1123
Converts a unix timestamp in to its RFC1123 representation. Version: 5.1 Arguments:
Return Value:
RFC1123 string representation of the unix timestamp provided.
Example:
translateError
Translates basic OS error to a simple string Version: 5.1 Arguments:
Return Value:
The return value can be a string of one of the following values:
- None
- Missing
- AccessDenied
- AccessInvalid
- NotEnoughSpace
- Locked
- NotSupported
- Unknown
unsetEnvironmentVariable
Unsets a process environment variable. Version: 6.2.2, 7.1.13 Arguments:
Return Value:
True if successful, false otherwise.
PlatformAccessPermissions
Access permission flags.nameFromId
Returns a string representing the specified flag values. Version: 5.1 Arguments:PlatformWebCredentialType
Web credential type constants. Version: 5.2nameFromId
Returns a string representing the specified constant values. Version: 5.2 Arguments:Process
Execute a process.createProcess
Creates a new process instance. Version: 3.6getId
Gets the ID of the process after it has been launched. Version: 3.6getApplicationName
Gets the name of the application. Version: 3.6getArguments
Gets the arguments that will be used when launching the process. Version: 3.6getAuthenticateTarget
Gets the authentication target for verification. Uses application if blank. Version: 3.6getElevationRights
Gets the elevation rights value that will be used for the process launch. Version: 3.6getRunningTime
Gets the time the application has been running in seconds. Version: 3.6getSHA1
Gets the SHA1 of the application executable. Version: 3.6getSHA1Target
Gets the optional target used for SHA1 calculation. Version: 3.6getShortApplicationName
Gets the filename of the application. Version: 3.6getShowWindow
Gets whether or not the process should be visible when launching. Version: 3.6 OS Support:- Windows
getStderr
Gets the pipe for the process standard error stream. Version: 6.1getStdin
Gets the pipe for the process standard input stream. Version: 6.1getStdout
Gets the pipe for the process standard output stream. Version: 6.1getWorkingDirectory
Gets the working directory used when launching the process. Version: 3.6launch
Launches the process. Version: 3.6 Example:release
Releases the instance. Version: 3.6setApplicationName
Sets the application name to launch. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setArguments
Sets the arguments that will be used when launching the process. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setAuthenticateCertStore
Sets the optional certificate store for verification. Uses app store if blank. Version: 7.2.27 Arguments:
Return Value:
True if successful, false otherwise.
setAuthenticateTarget
Sets the optional certificate authentication target for verification. Uses applicationName if blank. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setDigest
Sets the expected hash digest to verify against. If set, it will check the hash of the application prior to launching. Blank to skip check. Version: 7.2.27 (previously setSHA1 before 7.2.27, initially introduced in 3.6) Arguments:
Return Value:
True if successful, false otherwise.
setDigestTarget
Sets an optional target used for hash verification. Uses application path if blank. Version: 7.2.27 (previously setSHA1Target before 7.2.27, initially introduced in 3.6) Arguments:
Return Value:
True if successful, false otherwise.
setElevationRights
Sets the elevation rights that will be used when launching the process. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setShowWindow
Sets whether or not the process should be visible when launching. Version: 3.6 OS Support:- Windows
Return Value:
True if successful, false otherwise.
setStderr
Sets the pipe for the process standard error stream. Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
setStdin
Sets the pipe for the process standard input stream. Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
setStdout
Sets the pipe for the process standard output stream. Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
setWorkingDirectory
Sets the working directory used when launching the process. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
ProcessElevationRights
Elevation rights enumeration.nameFromId
Returns a string representing the specified enumeration value. Arguments:Registry
System registry functions. OS Support:- Windows
- default
- 32
- 64
- user
- performance
- machine
- root
- config
- desktopuser
deleteKey
Deletes a key in the registry. Version: 5.1, 3.6 as platform.registryDeleteKey Arguments:
Return Value:
True if successful, false otherwise.
Example:
deleteValue
Deletes a value in the registry. Version: 5.1, 3.6 as platform.registryDeleteValue Arguments:
Return Value:
True if successful, false otherwise.
Example:
getData
Gets a base-64 encoded string of a binary registry value. Version: 5.2 Arguments:
Example:
getInt32
Gets a 32-bit integer value from the registry. Version: 5.1, 3.6 as platform.getRegistryInt32 Arguments:
Example:
getInt64
Gets a 64-bit integer value from the registry. Version: 5.1 Arguments:
Example:
getString
Gets a string value from the registry. Version: 5.1, 3.6 as platform.getRegistryString Arguments:
Example:
keyExists
Checks to see if a registry key path exists. Version: 5.1, 3.6 as platform.registryKeyPathExists Arguments:
Return Value:
True if the key exists, false otherwise.
Example:
setData
Sets a binary value in the registry from a base-64 encoded string and creates the registry key if it does not already exist. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
Example:
setInt32
Sets a 32-bit integer value in the registry and creates the registry key if it does not already exist. Version: 5.1, 3.6 as platform.setRegistryInt32 Arguments:
Return Value:
True if successful, false otherwise.
Example:
setInt64
Sets a 64-bit integer value in the registry and creates the registry key if it does not already exist. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
setString
Sets a string value in the registry and creates the registry key if it does not already exist. Version: 5.1, 3.6 as platform.setRegistryString Arguments:
Return Value:
True if successful, false otherwise.
Example:
SkinFileExtract
getFilename
Gets the filename to extract from the skin. Version: 3.6setFilename
Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
getOutputFilename
Gets the filename on disk to extract to. Version: 3.6setOutputFilename
Sets the filename on disk to extract to Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
Example:
getBuffer
Gets the buffer. Version: 3.6 Arguments:
Return Value:
Returns length bytes of the buffer beginning at offset. Output is base64 encoded. If offset is invalid return value is null.
getBufferSize
Gets the size of the buffer. Version: 3.6start
Starts extraction. Version: 3.6createSkinFileExtract
Creates a new instance of SkinFileExtract. Version: 3.6 Example:release
Releases the instance. Version: 3.6SkinWindow
Host window functions.beginMove
Informs the native window of any movement so that the native/browser window can be synchronized. Version: 3.6beginSize
Informs the native window of any movement so that the native/browser window can be synchronized. Version: 3.6browseForFile
Show the file selection dialog center above the window. Version: 3.6 Arguments:
Return Value:
Notification center event with value that was selected by the user.
Changes in 6.1:
- Added new callback parameter
browseForFolder
Show the folder selection dialog center above the window. Version: 3.6 Arguments:
Return Value:
Notification center event with value that was selected by the user.
Changes in 6.1:
- Added new callback parameter
center
Centers the window in the current view port. Version: 3.6close
Closes the window. Version: 3.6getCanClose
Gets whether or not the operating system can close the window. Version: 5.1getCanHide
Gets whether or not the operating system can hide the window. Version: 5.1 Supported OS:- Windows
getCanMaximize
Gets whether or not the operating system can maximize the window. Version: 5.2getCanMinimize
Gets whether or not the operating system can minimize the window. Version: 5.1getCanMove
Gets whether or not the operating system can move the window. Version: 5.1getCanRestore
Gets whether or not the operating system can restore the window. Version: 5.1 Supported OS:- Windows
getCanShow
Gets whether or not the operating system can show the window. Version: 5.1 Supported OS:- Windows
- Macintosh
getConfig
Gets a configuration setting from the window config. Version: 3.6 Arguments:
Return Value:
Returns the configuration value or the default value if it is not found.
Example:
getDroppedFilePaths
Gets list of files or folders that were dropped. Should be accessed from with-in the JS DOM drop event handler. Version: 8.0.15 Return Value: Returns an array of files or folders, or empty if no files dropped. Example:getHeight
Gets the height of the window. Version: 3.6getMinHeight
Gets the minimum height of the window. Version: 3.6getMinimizeToNotificationArea
Gets whether or not the window will minimize to the notification area. Version: 3.6 OS Support:- Windows
getMinWidth
Gets the minimum width of the window. Version: 3.6getPopupFrame
Gets the type of popup window frame. Version: 6.1getScreenHeight
Gets the height of the screen the window is on. Version: 5.2getScreenInfo
Gets information about the screen the window is on. Version: 7.2.62 Return Value: Returns an object with screen information.getScreenWidth
Gets the width of the screen the window is on. Version: 5.2getTitle
Gets the title for the window. Version: 3.6getUseNotificationArea
Gets whether or not the window shows an icon the notification area. Version: 3.6 OS Support:- Windows
getWidth
Gets the width of the window. Version: 3.6getWindowFrame
Gets the type of window frame used. Version: 3.6getX
Gets the horizontal position of the window on the screen. Version: 3.6getY
Gets the vertical position of the window on the screen. Version: 3.6hide
Hides the window. Version: 3.6isActivated
Checks if the window is currently activated/focused. Version: 7.1isMaximized
Checks if the window is currently maximized. Version: 3.6isMinimized
Checks if the window is currently minimized. Version: 5.2isVisible
Checks if the window is currently visible. Version: 3.6loaded
Notify the client that the window has loaded. Prevents the client from showing a timeout message waiting to load. Calling skinWindow.show() is sufficient to prevent the timeout message from showing. In applications that automatically minimize to tray and do not show immediately, or applications that don’t show a window, it is necessary to call this function. Version: 5.1 Example:maximize
Maximizes the window. Version: 5.2messageBox
Shows and asks the user to response to a message box. Version: 5.1, 3.6 Arguments:
Return Value:
Returns the message box constant that the user selected.
Changes in 6.1:
- Added new callback parameter
minimize
Minimizes the window. Version: 3.6notify
Sends a notification message to the OS. Version: 3.6 Arguments:
Example:
restore
Restores the window after a minimize or maximize. Version: 3.6saveImage
Saves a PNG or BMP type image of the browser window to disk. Version: 3.6 Browser Support:- CEF
Changes in 6.1:
- Requires cef.offscreenRender enabled in app config
setBigIcon
Sets the big icon for the window. When disabled it shows the application icon. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setCanClose
Sets whether or not the operating system can close the window. Should be used during shutdown to indicate whether or not the window is ready to close. All interop instances should be released before setCanClose has been set true to ensure that instances are not leaked. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
setCanHide
Sets whether or not the operating system can hide the window. Version: 5.1 Supported OS:- Windows
Return Value:
True if successful, false otherwise.
setCanMaximize
Sets whether or not the operating system can maximize the window. Version: 5.2 Arguments:
Return Value:
True if successful, false otherwise.
setCanMinimize
Sets whether or not the operating system can minimize the window. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
setCanMove
Sets whether or not the operating system can move the window. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
setCanRestore
Sets whether or not the operating system can restore the window. Version: 5.1 Supported OS:- Windows
Return Value:
True if successful, false otherwise.
setCanShow
Sets whether or not the operating system can show the window. Version: 5.1 Supported OS:- Windows
- Macintosh
Return Value:
True if successful, false otherwise.
setContextMenu
Sets the context menu. Version: 3.6 Arguments:
NOTE: In order to use this feature useNotificationArea option must be set to true in the Window configuration.
Example:
setContextMenuSelect
Selects the context menu item. Version: 3.6 Arguments:
Example:
setCursor
Sets the cursor for the window. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setMinimizeToNotificationArea
Sets whether or not the window will minimize to the notification area. Version: 3.6 OS Support:- Windows
Return Value:
True if successful, false otherwise.
setMinSize
Sets the minimum size of the window. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setNotificationAreaIcon
Sets the notification area icon for the window. Version: 3.6 OS Support:- Windows
Return Value:
True if successful, false otherwise.
setOrigin
Sets the origin of the window. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setSize
Sets the size of the window. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
Changes:
- 5.1 - Automatically adjusts for monitor’s DPI
setSmallIcon
Sets the small icon for the window. When disabled it shows the application icon. Version: 3.6 OS Support:- Windows
Return Value:
True if successful, false otherwise.
setTaskbarOverlay
Sets the taskbar icon overlay. Version: 5.1 Arguments:
Notes:
- This function should be called after the window has first been shown.
setTaskbarProgress
Sets the progress in the task bar. Version: 5.1 OS Support: Some operating systems may not support showing progress in the task bar. Arguments:
Return Value:
True if successful, false otherwise.
Example:
setTitle
Sets the title for the window. Version: 3.6setUseNotificationArea
Sets whether or not the window shows an icon the notification area. Version: 3.6 OS Support:- Windows
Return Value:
True if successful, false otherwise.
setWindowFrame
Sets the type of window frame. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
Additional Notes:
- If the specified windowFrame does not exist, it will default to Normal.
show
Shows the window. Version: 3.6SkinWindowNotify
Notifcation type enumeration for use with skinWindow.notify .nameFromId
Returns a string representing the specified enumeration value. Arguments:SkinWindowMessageBox
Message box type flags for use with skinWindow.messageBox .
Changes in 5.2:
- Added info, warning, and error
nameFromId
Returns a string representing the specified enumeration value. Arguments:TextFileReader
Read a text file.createTextReader
Creates a new TextReader object. Version: 3.6 Example:getBufferSize
Gets the maximum size of the read buffer Version: 3.6getBytesLeft
Gets the bytes left to read. Version: 3.6getFileName
Gets the path to the file to read. Version: 3.6getFileSize
Gets the size of the file. Version: 3.6release
Releases the instance. Version: 3.6setBufferSize
Sets the maximum size of the read buffer Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
setFileName
Sets the path of the file to read. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
start
Starts reading the file. Version: 3.6TextFileWriter
close
Closes the file. Version: 3.6createTextWriter
Creates a new TextWriter object. Version: 3.6open
Opens a file for writing. Version: 3.6 Arguments:
Return Value:
True if successful, false otherwise.
release
Releases the instance. Version: 3.6write
Writes a string to a file Version: 3.6 Arguments:
Return Value:
Returns the number of bytes written.
WebGet
authorize
Validates whether or not a url matches hostname whitelist. Version: 5.2 Arguments:
Return Value:
True if authorized, false otherwise.
Example:
redirect
Expands the string with using the redirect substitutes. Version: 3.6 Arguments:
Return Value:
Returns the expanded string.
Example:
redirectAdd
Adds a webget url redirection entry. Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
redirectAddMacro
Adds a webget url redirection key/value macro. Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
redirectClearAll
Removes all URL redirections and macros. Version: 5.1 Return Value: True if successful, false otherwise. Example:redirectRemove
Removes a webget url redirection entry. Version: 5.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
redirectRemoveMacro
Removes a webget url redirection key/value macro Version: 6.1 Arguments:
Return Value:
True if successful, false otherwise.
Example:
WebGetRedirect
Redirection flagsnameFromId
Returns a string representing the specified enumeration value. Arguments:WebGetPcreCompileOption
Regular expression compile options Version: 6.1nameFromId
Returns a string representing the specified enumeration value. Arguments:WebGetPcreSubstituteOption
Regular expression substitute options Version: 6.1nameFromId
Returns a string representing the specified enumeration value. Arguments:Wmi
Version: 5.2.0 Supported OS:- Windows
query
Querys the Windows Management Instrumentation. Version: 3.6 Arguments:
Return Value:
Returns JSON results upon running the query or null upon failure.

