I encountered the following line in an automation script and would like to know what is being checked:
if (((AlarmEventMessage)dmsMessage).SourceID == 23)
Would there be an Enum type in SLNetTypes.dll that I could use to replace the number with to improve clarity?
Thomas Cauwelier [SLC] [DevOps Advocate] Selected answer as best 18th October 2022
The code is checking whether the alarm is being generated by DataMiner's correlation engine. You could use SLEnumValues.CorrelationEngine (in the Skyline.DataMiner.Net.Enums namespace) to get rid of the magic number.
Thomas Cauwelier [SLC] [DevOps Advocate] Selected answer as best 18th October 2022