Hi
I have a QAction in my protocol and I would like to get the element IP and SNMP community string details from my QAction. I know using class library such as getDms() method might work. I d like to know if there is any more efficient way to do that?
Thanks
Esteban Pardo [SLC] [DevOps Advocate] Posted new comment 21st October 2025
Hi,
To retrieve the IP, you can use ip | DataMiner Docs or polling ip | DataMiner Docs (whether you also want the polling port or not, respectively).
For the community string details, the only way I know how would indeed be with something like Class Library.
João Severino [SLC] [DevOps Catalyst] Answered question 31st July 2025
Hey Peng Fei.
I did this regarding the Community string and did the trick
IDms dms = protocol.GetDms();
IDmsElement element = dms.GetElement(new DmsElementId(protocol.DataMinerID, protocol.ElementID));
string getCommunity = element.Connections.OfType<ISnmpV2Connection>().FirstOrDefault().GetCommunityString;
Cheers!