Utilisez cette instruction pour la compilation conditionnelle dans l’éditeur ST.
#IF IsSystemVariableSupported('sys_bIsPlcInTestMode') <> 0 #THEN
(*condition TRUE: first part is compiled and executed*)
#ELSE
(*condition FALSE: second part is compiled and executed*)
OutputCompilerWarning('PLC does not support the test mode');
#END_IF;
Avec un automate FP-S, ce code renvoie l’avertissement suivant :