Forum Migration Notice
Update (2026-01-21): The user forums are now in read-only mode pending the data migration.

Update (2026-01-12): The user forums will be put into read-only mode on the 21st of January, 00:00 CET, to prepare for the data migration.

We're transitioning to a more modern community platform by beginning of next year. Learn about the upcoming changes and what to expect.

PC SDK: How to check if variable is persistent?

Hi,


I was bitten by the fact that RapidData.ValueChanged only works for persistent variables. 

(No warning/log/whatnot from the code. Just no output...)
It took me a while to find the fine-print regarding that method

Anyway, I figured I could check if it is persistent or not, and thus warn (or start polling) if not.

The IsTaskPers property _seems_ to check only for TASK PERS vs PERS, not PERS, if I can read the doc right (see below). The last remark muddles things a bit.
Is there any other way I can check for PERS to prevent the same mistake in the future?


Cheers,
/Marcus


"
public bool IsTaskPers { get; }
Checks whether the RAPID data is declared PERS or TASKPERS.
Only of interest for persistent data.

Property Value Booleanimageimage
true if the RAPID data is declared TASKPERS;
otherwise false.

Remarks
Will return false if used with RapidData that is not
declared as persistent (but constant for example). 
"