I need to make a change in an old collector that is using DMSClass.
DIS indicated that I need to move towards nugets (fix button) and replace the old class lib. (fix button)
However the code was using DMSClass that is now unknown and I don't know what to replace it with to have the code running again.
I've added the Core DataMiner protocol nuget.
Please let me know what to replace the below code with.
DMSClass oDMS = new DMSClass();
Object oReturnValue = new Object();
oDMS.Notify(91/*DMS_GET_ELEMENT_STATE*/, 0, iDataMinerID, iElementID, out oReturnValue);
if (Convert.ToString(oReturnValue) == "active")
{
return true;
}
Hi Mieke,
You can use below code when using NuGet Skyline.DataMiner.Core.DataMinerSystem.Protocol
IDms myDms = protocol.GetDms();
IDmsElement myElement = myDms.GetElement(new DmsElementId(iDataMinerId, iElementId));
if (myElement.State == ElementState.Active)
{
return true;
}