Accessibility of PROGRAM Variables - Manual - Software Loader - The AX SIMATIC SW-Loader. - Software Loader (sld),tool

Software Loader CLI Tool (sld)

Portfolio
SIMATIC AX
Product
Software Loader
Software version
3.2.2
Edition
04/2025
Language
English (original)
Package Name
@ax/sld

The accessibility of a PROGRAM is ReadWrite as default for applications compiled with the current STC. Therefore, the definition of accessibility for the whole PROGRAM, for a complete VAR section or for individual variables in its VAR section will apply always.

CONFIGURATION config
    {S7.extern=ReadOnly}       // this pragma is ignored. The accessibility is always 'ReadWrite'!
    PROGRAM P1 : Prg;
END_CONFIGURATION

PROGRAM Prg
    VAR 
        {S7.extern=ReadOnly}
        x : INT;  
    END_VAR            
    ; 
END_PROGRAM