SetValuesXY

SetValuesXY 1:

Set the xy-coordinates of this position.

Syntax

Definition:

METHOD SetValuesXY
VAR_INPUT
    x : LREAL;
    y : LREAL;
END_VAR

SetValuesXY 2: Inputs

Name

Type

Description

x

LREAL

x-component of the position.

y

LREAL

y-component of the position.

Example: PositionXY.SetValuesXY

PLC declaration

VAR
   position  : PositionXY;
   x : LREAL := 4.3;
   y : LREAL := 2.5;
END_VAR

PLC implementation

position.x := 0;
position.y := 0;
position.SetValuesXY(x, y);

Expected result

position.x = 4.3
position.y = 2.5