Skip to content
DataMiner DoJo

More results...

Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors
Search in posts
Search in pages
Search in posts
Search in pages
Log in
Menu
  • Updates & Insights
  • Questions
  • Learning
    • E-learning Courses
    • Empower Replay: Limited Edition
    • Tutorials
    • Open Classroom Training
    • Certification
      • DataMiner Fundamentals
      • DataMiner Configurator
      • DataMiner Automation
      • Scripts & Connectors Developer: HTTP Basics
      • Scripts & Connectors Developer: SNMP Basics
      • Visual Overview – Level 1
      • Verify a certificate
    • Video Library
    • Books We Like
    • >> Go to DataMiner Docs
  • Expert Center
    • Solutions & Use Cases
      • Solutions
      • Use Case Library
    • Markets & Industries
      • Media production
      • Government & defense
      • Content distribution
      • Service providers
      • Partners
      • OSS/BSS
    • Agile
      • Agile Webspace
      • Everything Agile
        • The Agile Manifesto
        • Best Practices
        • Retro Recipes
      • Methodologies
        • The Scrum Framework
        • Kanban
        • Extreme Programming
      • Roles
        • The Product Owner
        • The Agile Coach
        • The Quality & UX Coach (QX)
    • DataMiner DevOps Professional Program
      • About the DevOps Program
      • DataMiner DevOps Support
  • Downloads
  • More
    • DataMiner Releases & Updates
    • Feature Suggestions
    • Climb the leaderboard!
    • Swag Shop
    • Contact
    • Global Feedback Survey
  • PARTNERS
    • All Partners
    • Technology Partners
    • Strategic Partner Program
    • Deal Registration
  • >> Go to dataminer.services

Alarm ID changes on Masking?

Solved269 views31st January 2025#automationscript alarm
1
Apurva Tandon [DevOps Advocate]1.61K 30th January 2025 0 Comments

Hi,

I am seeing that when I mask a particular alarm the id of it gets changed.
So my scenario is, I show the alarms on LCA and want to give the functionality to user to mask or unmask the alarm from LCA via this script

var dmsElement = _dms.GetElement(element);
SetAlarmStateMessage maskAlarm = new SetAlarmStateMessage
{
AlarmId = Convert.ToInt32(alarmId),
DataMinerID = Convert.ToInt32(dmaId),
ElementID = dmsElement.Id,
State = 8,
};
maskAlarm.DesiredStatus = AlarmUserStatus.UnMask;
var response = _engine.SendSLNetMessage(maskAlarm);

So masking happens fine, I save the alarm id in DOM

Now, when he clicks for unmasking

I do :
var instance = domHelper.DomInstances.Read(domFilter).FirstOrDefault();
var elementName = instance.GetFieldValue<string>(Mcr_Dashboard.Sections.AlarmDetails.Id, Mcr_Dashboard.Sections.AlarmDetails.ElementName);
_engine.Log("AddOrReplaceFieldValue done");
var dmaId = instance.GetFieldValue<Int64>(Mcr_Dashboard.Sections.AlarmDetails.Id, Mcr_Dashboard.Sections.AlarmDetails.DmaId);
_engine.Log("AddOrReplaceFieldValue done");
if (instance != null)
{
var dmsElement = _dms.GetElement(elementName.Value);
domHelper.DomInstances.Delete(instance);
SetAlarmStateMessage unmaskAlarm = new SetAlarmStateMessage
{
AlarmId = Convert.ToInt32(alarmId),
DataMinerID = Convert.ToInt32(dmaId),
ElementID = dmsElement.Id,
State = 9,
};
unmaskAlarm.DesiredStatus = AlarmUserStatus.UnMask;
_engine.SendSLNetMessage(unmaskAlarm);

But, here I see since the alarm ID is changed it cannot find out and hence unmasking fails,
Is there any way if the ID is changing to have the new id after masking and then save in DOM

Apurva Tandon [DevOps Advocate] Selected answer as best 31st January 2025

1 Answer

  • Active
  • Voted
  • Newest
  • Oldest
5
Miguel Obregon [SLC] [DevOps Catalyst]18.99K Posted 30th January 2025 0 Comments

Hi Apurva,

Can you try masking the alarm root ID? Whenever there is an update on the alarm, a new alarm ID will be generated. However, the alarm toot ID will be the same.

Hope it helps.

Apurva Tandon [DevOps Advocate] Selected answer as best 31st January 2025
You are viewing 1 out of 1 answers, click here to view all answers.
Please login to be able to comment or post an answer.

My DevOps rank

DevOps Members get more insights on their profile page.

My user earnings

0 Dojo credits

Spend your credits in our swag shop.

0 Reputation points

Boost your reputation, climb the leaderboard.

Promo banner DataMiner DevOps Professiona Program
DataMiner Integration Studio (DIS)
Empower Katas
Privacy Policy • Terms & Conditions • Contact

© 2025 Skyline Communications. All rights reserved.

DOJO Q&A widget

Can't find what you need?

? Explore the Q&A DataMiner Docs

[ Placeholder content for popup link ] WordPress Download Manager - Best Download Management Plugin