ConnectionType - property of the tvTrend object
Description:
Connection type to trends server.
Syntax:
Long ConnectionType
Values:
0 - trend object is not connected to any data source
1 - local connection to the trends server that runs in the same application as the viewer
2 - connection to the remote trends server by means of the Web services. The data are sent in the XML format.
Note:
Property access
for read and write.
This property is also functional in
Web panels.
After writing into this property, it is necessary to call the
Connect method with the
nType=0 parameter.
Example:
JavaScriptVBScriptSelect and copy to clipboard
var oTView = pMe.Items("../TrendView");
var oTrend = oTView.Trends(0);
if (oTrend)
{
var nConnType = oTrend.ConnectionType;
// Reading from the property
// or
oTrend.ConnectionType = 2;
// Writing into the property
}
Dim oTView
Set oTView = pMe.Items("../TrendView")
Dim oTrend
Set oTrend = oTView.Trends(0)
If Not oTrend Is Nothing Then
Dim nConnType
nConnType = oTrend.ConnectionType
' Reading from the property
' or
oTrend.ConnectionType = 2
' Writing into the property
End If