andyromero

GetPoints2 function

Discussion created by andyromero on May 28, 2013
Latest reply on May 29, 2013 by andyromero

Hi

 

Im a newbie in PISDK development.

 

Im trying to invoke the method getPoints2 of Interface IGetPoints2.

 

The following code performs well

 

StringBuilder sb = new StringBuilder();
foreach (KeyValuePair<String, Decimal?> item in tags_unitOfMeasure)
{
sb.Append("TAG='" + item.Key + "' OR ");
}
string csvWithQuote = sb.Remove(sb.Length - 3, 3).ToString();
PISDKCommon.NamedValues nvRetrievalAttributes = null;
PISDK.IGetPoints2 points = (PISDK.IGetPoints2) piServer;
return points.GetPoints2(csvWithQuote, nvRetrievalAttributes, PISDK.GetPointsRetrievalTypes.useGetPoints);

 

But i dont know how to pass the  list of point attributes to be returned by this call.

 

Im passing an null  nvRetrievalAttributes. 

 

How can i pass the list attributes to be returned?  I dont know how instantiate a implementation of interface PISDKCommon.NamedValues to do the job.

 

Thanks so much for any help

 

 

Outcomes