1. Object JSWorkflowProperty

    Article: AN0002046Updated:

    This object provides properties of the running workflow instance. You can read and change the properties. You cannot create a new property of delete it. This can be done only in the workflow design.

    Object properties


    Name Description
    string GetString(string code) Function returns a text value of the property.
    int? GetInteger(string code) Function returns an integer value of the property.
    bool? GetBoolean(string code) Function returns a boolean value (YES/NO) of the property.
    DateTime? GetDateTime(string code) Function returns a date value of the property.
    void SetString(string code, string value) Function saves a text value in the property.
    void SetInteger(string code, int? value) Function saves an integer value in the property.
    void SetBoolean(string code, bool? value) Function saves a boolean value (YES/NO) in the property.
    void SetDateTime(string code, DateTime? value) Function saves a date value in the property.

    Properties are accessed by a code that is unique within the workflow instance.

    If you try to save a property value of the wrong data type, an error is raised. E.g.: if you have a property ABC, that is a text type and you want to save an integer into it, an exception occurs.


    Example of reading property 'i' of the integer data type and saving value 1 into it:

    var i = OGActualRun.Property.GetInteger( 'i');
    OGActualRun.Property.SetInteger( 'i', 1);