XSalScript
Namespace: PPJ.Runtime.XSal
Assembly: PPJ.Web.XSal.49 (4.9.0.0)
Implementation of XSalScript
- C#
- VB.NET
public class XSalScript
Public Class XSalScript
Constructors
XSalScript()
Constructs a new empty XSalScript object.
XSalScript(source)
Constructs a new XSalScript object and compiles the specified source code.
| Name | Type | Description |
|---|---|---|
| source | String |
Properties
Context
Object: Returns/Sets the context for the execution of the script.
CSharpSyntax
Boolean: Returns/Sets the C# flag to turn on the preprocessor. When this property is false, the preprocessor tries to adapt old XSalScript syntax to C# syntax.
DebugMode
Boolean: Returns/Sets the debug mode. When on the script will popup the error message box.
Handle
HasErrors
Boolean: Returns true if the script object contains a list of errors.
Interpreter
ScriptEngine: Returns the instance of the interpreter used by XSalScript.
LastError
String: Returns the last error message.
Source
String: Returns/Sets the script source code.
Methods
AddLine(line)
Adds a line to the script.
| Parameter | Type | Description |
|---|---|---|
| line | String |
Returns: Boolean.
Dispose()
FromHandle(handle)
| Parameter | Type | Description |
|---|---|---|
| handle | IntPtr |
Returns: XSalScript.
Run()
Executes the compiled script and returns the return value.
Returns: String.