RETURN Statement

Help Contents

Introduction

The Structured Text RETURN statement exits a Program Unit early.

Example

Function CheckValue : Bool
    Var_Input Value : Int; End_Var

    if Value = 0 Or Value = 2 Then
        CheckValue := false;
        return;
    end_if;

    CheckValue := True;
End_Function

Further Information

Structured Text

For other Structured Text (ST) statement types.

Glossary

For the meaning of terms used in Fernhill SCADA.