sarvu wrote:My tag mask is in variable place and commodity.
I could not get the points from PI server with the below code.I don't know the reason for this.
If ConnectToPI() Then
pList = PIServer.GetPoints("tag='*" & place & "* " & Commodity & "*'")
For Each pPoint In pList
CommodityTag = pPoint
pVal = CommodityTag.Value(TimeStamp1)
If pVal Is Nothing Then
Else
Return CommodityTag
End If
Next
End If
I think your filter expression is not appropriate. Do you have point attribute "Commodity"??? or "Place"???
For example, you always have attribute "pointsource", and some points hahe pointsource 'Z'. So, You can set filter to "pointsource='Z*'"
In C# syntax it will look like:
Code:
PointList points = _piServer.GetPoints("pointsource = 'Z*'");