Hi Alvxx1!
In the PLUS+1 GUIDE v9.0 User Manual (UM, found under Help in the menu bar) on page 318 you will find the following about the
Set Array Element:
- X1 = A2 if A1 (the set position) is positively or negatively out-of-bounds
This means that if the A1 entry is (for example) -1, then the output array will have the same value as the input array.
So, In your case, simply set this input to -1 when the Boolean value is false. (This is also shown in the first image under “Example2” on the same page in the manual.)
Alternatively, since you are familiar with Ladder Logic, you can simply use that instead in PLUS+1 GUIDE. PLUS+1 GUIDE is supporting Structured Text since version 6.0, and Ladder Logic + Function Block Diagram since version 8.0. See chapter “IEC61131-3 PLC Languages” on page 525 in the same manual as above for more information on this subject.
One tip, when you have the component you would like to use highlighted in the component tab on your right in GUIDE, hit F1 and a dialog box will open for PLUS+1 GUIDE help where you can find some more info without having to open the UM.
Hope this helps!
Best regards
Nilla
PLUS+1 Helpdesk