AdvancedHMI Software

General Category => Support Questions => Topic started by: frenelius on May 13, 2021, 02:39:57 AM

Title: Change form only if it is allowed from PLC
Post by: frenelius on May 13, 2021, 02:39:57 AM
Hello,
I would like to allow access into a specific form only if a PLC memory address has a certain value.
(It has been authorized from the PLC).

How could I do that?

I have tried using an IF condition in the MainForm designer -> form change button initialization, reading the memory value with a basiclabel but it will not work as expected.

Thank you.
Title: Re: Change form only if it is allowed from PLC
Post by: frenelius on May 13, 2021, 03:16:40 AM
I guess what I need is the PLCAddressVisible property, but as a decimal value, not a bool.
Thank you.
Title: Re: Change form only if it is allowed from PLC
Post by: MajorFault on May 13, 2021, 10:30:01 AM
Send AHMI a BOOL from the PLC.  If the current PLC value is decimal, then write the code in the PLC to set a BOOL.

Personally, I would use enable vs visible, but both will prevent someone from changing forms.