Other Options
- The SaveOptions Subroutine saves the current Option configuration.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string networknode = "";
oasc.SaveOptions(networknode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine("Save Successful");
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim networknode As String = ""
oasc.SaveOptions(networknode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine("Save Successful")
End If
End Sub
End Class
End Namespace
- The LoadOptions Subroutine loads the current Option configuration from the default Options file.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string networknode = "";
oasc.LoadOptions(networknode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine("Load Successful");
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim networknode As String = ""
oasc.LoadOptions(networknode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine("Load Successful")
End If
End Sub
End Class
End Namespace
- GetAutoRuntime Function returns automatic Start of Runtime Mode when the Service first Starts.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetAutoRuntime(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetAutoRuntime(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetAutoRuntime Subroutine sets automatic Start of Runtime Mode when the Service first Starts.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setRuntime = false;
oasc.SetAutoRuntime(setRuntime, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setRuntime As Boolean = False
oasc.SetAutoRuntime(setRuntime, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetStartRuntimeDelay Function returns the amount of time in seconds that will delay the starting Runtime Mode when the Service first Starts if the AutoRuntime property is enabled.
- Returns an Int32.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetStartRuntimeDelay(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetStartRuntimeDelay(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetStartRuntimeDelay Subroutine sets the amount of time in seconds that will delay the starting Runtime Mode when the Service first Starts if the AutoRuntime property is enabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 0)
{
Console.WriteLine("0 is the lowest number possible", "Error setting StartRuntimeDelay");
return;
}
string ErrorString = "";
oasc.SetStartRuntimeDelay(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 0 Then
Console.WriteLine("0 is the lowest number possible", "Error setting StartRuntimeDelay")
Return
End If
Dim ErrorString As String = ""
oasc.SetStartRuntimeDelay(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetOPCServerWatchDogRate Function returns the amount of time in seconds that wait for new data from each OPC Server Group before disconnecting and reconnecting the OPC Server Group.
- Returns an Int32.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetOPCServerWatchDogRate(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetOPCServerWatchDogRate(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetOPCServerWatchDogRate Subroutine sets the amount of time in seconds that wait for new data from each OPC Server Group before disconnecting and reconnecting the OPC Server Group.
- Set to 0 to disable the OPC Server Watchdog.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 0)
{
Console.WriteLine("0 is the lowest number possible", "Error setting OPCServerWatchDogRate");
return;
}
string ErrorString = "";
oasc.SetOPCServerWatchDogRate(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 0 Then
Console.WriteLine("0 is the lowest number possible", "Error setting OPCServerWatchDogRate")
Return
End If
Dim ErrorString As String = ""
oasc.SetOPCServerWatchDogRate(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetTimeStampFromOPC Function returns TimeStamp from OPC Servers which enables setting the TimeStamp of when all Tag Parameters with OPC as the data source to the TimeStamp from the OPC Server.
- When set to False the TimeStamp comes for the CPU clock of the OAS Service containing the Tag.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string NetworkNode = "";
bool CurrentValue = oasc.GetTimeStampFromOPC(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim NetworkNode As String = ""
Dim CurrentValue As Boolean = oasc.GetTimeStampFromOPC(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetTimeStampFromOPC Subroutine sets TimeStamp from OPC Servers which enables setting the TimeStamp of when all Tag Parameters with OPC as the data source to the TimeStamp from the OPC Server.
- When set to False the TimeStamp comes for the CPU clock of the OAS Service containing the Tag.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string NetworkNode = "";
oasc.SetTimeStampFromOPC(true, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim NetworkNode As String = ""
oasc.SetTimeStampFromOPC(True, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLogErrors Function returns the Log Errors mode.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string NetworkNode = "";
bool CurrentValue = oasc.GetLogErrors(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim NetworkNode As String = ""
Dim CurrentValue As Boolean = oasc.GetLogErrors(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetLogErrors Subroutine sets the Log Errors mode.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string ErrorString = "";
string NetworkNode = "";
bool setLogs = false;
oasc.SetLogErrors(setLogs, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim ErrorString As String = ""
Dim NetworkNode As String = ""
Dim setLogs As Boolean = False
oasc.SetLogErrors(setLogs, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLogErrorsPath Function returns the Error Log Path.
- Returns a String of the path to log errors to when LogErrors is enabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
path = oasc.GetLogErrorsPath(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine(path);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
path = oasc.GetLogErrorsPath(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine(path)
End If
End Sub
End Class
End Namespace
- SetLogErrorsPath Subroutine sets the Error Log Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
oasc.SetLogErrorsPath(path, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
oasc.SetLogErrorsPath(path, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetDeleteLogErrors Function returns state of automatic deleting of error log.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetDeleteLogErrors(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetDeleteLogErrors(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetDeleteLogErrors Subroutine sets automatic deleting of error log.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
bool setDelete = false;
string ErrorString = "";
oasc.SetDeleteLogErrors(setDelete, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim setDelete As Boolean = False
Dim ErrorString As String = ""
oasc.SetDeleteLogErrors(setDelete, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetDeleteLogErrorsDays Subroutine sets the Number of Days for Automatic Deletion of the Error Log.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 0)
{
Console.WriteLine("0 is the lowest number possible", "Error setting DeleteLogErrorsDays");
return;
}
string ErrorString = "";
oasc.SetDeleteLogErrorsDays(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 0 Then
Console.WriteLine("0 is the lowest number possible", "Error setting DeleteLogErrorsDays")
Return
End If
Dim ErrorString As String = ""
oasc.SetDeleteLogErrorsDays(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetDeleteLogErrorsDays Function returns the Number of Days for Automatic Deletion of the Error Log.
- Returns an Int32 for the number of days when the Error Log files will be kept.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetDeleteLogErrorsDays(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetDeleteLogErrorsDays(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLogTransactions Function returns the Log Transactions mode.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetLogTransactions(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
Console.WriteLine("Enabled");
else
Console.WriteLine("Disabled");
}
else
Console.WriteLine(ErrorString);
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public
Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetLogTransactions(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetLogTransactions Subroutine sets the Log Transactions mode.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setLog = false;
oasc.SetLogTransactions(setLog, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setLog As Boolean = False
oasc.SetLogTransactions(setLog, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLogTransactionsPath Function returns the Transaction Log Path.
- Returns a String of the path to log transaction to when LogTransactions is enabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
path = oasc.GetLogTransactionsPath(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine(path);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
path = oasc.GetLogTransactionsPath(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine(path)
End If
End Sub
End Class
End Namespace
- SetLogTransactionsPath Subroutine sets the Transaction Log Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
oasc.SetLogTransactionsPath(path, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
oasc.SetLogTransactionsPath(path, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetServiceUserName Function returns the User Name assigned to the Service.
- Returns a String of the User Name assigned to the Service.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string username = "";
username = oasc.GetServiceUserName(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine(username);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim username As String = ""
username = oasc.GetServiceUserName(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine(username)
End If
End Sub
End Class
End Namespace
- SetServiceUserName Subroutine sets the User Name assigned to the Service.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string username = "";
oasc.SetServiceUserName(username, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim username As String = ""
oasc.SetServiceUserName(username, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetServicePassword Function returns the Password assigned to the Service.
- Returns a String of the Password assigned to the Service.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string password = "";
password = oasc.GetServicePassword(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim password As String = ""
password = oasc.GetServicePassword(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetServicePassword Subroutine sets the Password assigned to the Service.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string password = "";
oasc.SetServicePassword(password, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim password As String = ""
oasc.SetServicePassword(password, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetStoreDataLogBufferToDisk Function returns the Store Data Log Buffer to Disk state.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetStoreDataLogBufferToDisk(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetStoreDataLogBufferToDisk(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetStoreDataLogBufferToDisk Subroutine sets Store Data Log Buffer to Disk.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setStore = false;
oasc.SetStoreDataLogBufferToDisk(setStore, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setStore As Boolean = False
oasc.SetStoreDataLogBufferToDisk(setStore, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetStoreDataLogBufferPath Function returns the Data Log Buffer Path.
- Returns a String of the path to buffer data logging data on error to when StoreDataLogBufferToDisk is enabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string dataPath = oasc.GetStoreDataLogBufferPath(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim dataPath As String = oasc.GetStoreDataLogBufferPath(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetStoreDataLogBufferPath Subroutine sets the Data Log Buffer Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string bufferPath = "";
oasc.SetStoreDataLogBufferPath(bufferPath, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim bufferPath As String = ""
oasc.SetStoreDataLogBufferPath(bufferPath, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLimitDiskBuffering Function returns Limit Disk Buffering.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetLimitDiskBuffering(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetLimitDiskBuffering(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetLimitDiskBuffering Subroutine sets Limit Disk Buffering.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setLimit = false;
oasc.SetLimitDiskBuffering(setLimit, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setLimit As Boolean = False
oasc.SetLimitDiskBuffering(setLimit, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetLimitDiskBufferingTime Function returns the Limit Disk Buffering Time in hours.
- Returns an Int32 for the number of hours to buffer data logging to disk when in error.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetLimitDiskBufferingTime(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetLimitDiskBufferingTime(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetLimitDiskBufferingTime Subroutine sets the Limit Disk Buffering Time in hours.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 0)
{
Console.WriteLine("0 is the lowest number possible", "Error setting LimitDiskBufferingTime");
return;
}
string ErrorString = "";
oasc.SetLimitDiskBufferingTime(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 0 Then
Console.WriteLine("0 is the lowest number possible", "Error setting LimitDiskBufferingTime")
Return
End If
Dim ErrorString As String = ""
oasc.SetLimitDiskBufferingTime(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetMaximumDataLoggingRecords Function returns the Maximum Data Logging Records to buffer to RAM when in error.
- Returns an Int32 for the number of records to buffer data logging to RAM in error.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetMaximumDataLoggingRecords(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetMaximumDataLoggingRecords(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetMaximumDataLoggingRecords Subroutine sets the Maximum Data Logging Records to buffer to RAM when in error.
- Value is the desired value for the Maximum Data Logging Records to buffer to RAM when in error
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 100)
{
Console.WriteLine("100 is the lowest number possible", "Error setting MaximumDataLoggingRecords");
return;
}
string ErrorString = "";
oasc.SetMaximumDataLoggingRecords(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 100 Then
Console.WriteLine("100 is the lowest number possible", "Error setting MaximumDataLoggingRecords")
Return
End If
Dim ErrorString As String = ""
oasc.SetMaximumDataLoggingRecords(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetWriteWhenBad Function returns the current state of writing to OPC Items when bad with OPC Tunnel.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetWriteWhenBad(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetWriteWhenBad(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetWriteWhenBad Subroutine sets the current state of allowing writing to OPC Items when bad with OPC Tunnel.
- Value is the desired value for Allow Writes to OPC Items When Bad with OPC Tunnel.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
bool setWrite = false;
string ErrorString = "";
oasc.SetWriteWhenBad(setWrite, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim setWrite As Boolean = False
Dim ErrorString As String = ""
oasc.SetWriteWhenBad(setWrite, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetOEMCode Function returns the OEM Code.
- Returns a String containing the OEM Code.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string OEMCode = oasc.GetOEMCode(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.Write(ErrorString);
}
else
{
Console.Write(OEMCode);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim OEMCode As String = oasc.GetOEMCode(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.Write(ErrorString)
Else
Console.Write(OEMCode)
End If
End Sub
End Class
End Namespace
- SetOEMCode Subroutine sets the OEM Code.
- Value is the desired value for OEM Code.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- ptional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string OEMCode = "";
oasc.SetOEMCode(OEMCode, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim OEMCode As String = ""
oasc.SetOEMCode(OEMCode, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetClientPacketRate Function returns Client Packet Rate in milliseconds.
- Returns an Int32 for the Client Packet Rate.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
Int32 CurrentValue = 0;
CurrentValue = oasc.GetClientPacketRate(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
Console.WriteLine(CurrentValue.ToString());
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Int32 = 0
CurrentValue = oasc.GetClientPacketRate(NetworkNode, ErrorString)
If ErrorString = "Success" Then
Console.WriteLine(CurrentValue.ToString())
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetClientPacketRate Subroutine sets the Client Packet Rate.
- Value is the desired Client Packet Rate in milliseconds, range is 10 ms to 10,000 ms.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
Int32 ValueInt32 = 0;
if (ValueInt32 < 10) { Console.WriteLine("10 is the lowest number possible", "Error setting ClientPacketRate"); return; }
if (ValueInt32 > 10000)
{
Console.WriteLine("10,000 is the highest number possible", "Error setting ClientPacketRate");
return;
}
string ErrorString = "";
oasc.SetClientPacketRate(ValueInt32, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine("ClientPacketRate value is invalid");
return;
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Private Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ValueInt32 As Int32 = 0
If ValueInt32 < 10 Then
Console.WriteLine("10 is the lowest number possible", "Error setting ClientPacketRate")
Return
End If
If ValueInt32 > 10000 Then
Console.WriteLine("10,000 is the highest number possible", "Error setting ClientPacketRate")
Return
End If
Dim ErrorString As String = ""
oasc.SetClientPacketRate(ValueInt32, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine("ClientPacketRate value is invalid")
Return
End If
End Sub
End Class
End Namespace
- GetIncludeOPCErrorsInErrorLog Function returns Include OPC Errors In Error Log.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetIncludeOPCErrorsInErrorLog(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetIncludeOPCErrorsInErrorLog(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetIncludeOPCErrorsInErrorLog Subroutine sets Include OPC Errors In Error Log.
- Value is the desired value for Include OPC Errors In Error Log.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setInclude = false;
oasc.SetIncludeOPCErrorsInErrorLog(setInclude, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setInclude As Boolean = False
oasc.SetIncludeOPCErrorsInErrorLog(setInclude, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetIncludeTagErrorsInErrorLog Function returns Include Tag Errors In Error Log.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetIncludeTagErrorsInErrorLog(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetIncludeTagErrorsInErrorLog(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetIncludeTagErrorsInErrorLog Subroutine sets Include Tag Errors In Error Log.
- Value is the desired value for Include Tag Errors In Error Log.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setInclude = false;
oasc.SetIncludeTagErrorsInErrorLog(setInclude, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setInclude As Boolean = False
oasc.SetIncludeTagErrorsInErrorLog(setInclude, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetEnableTimeOnAndCountFile Function returns Enable Time On And Count File.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetEnableTimeOnAndCountFile(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetEnableTimeOnAndCountFile(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetEnableTimeOnAndCountFile Subroutine sets Enable Time On And Count File.
- Value is the desired value for Enable Time On And Count File.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setEnable = false;
oasc.SetEnableTimeOnAndCountFile(setEnable, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setEnable As Boolean = False
oasc.SetEnableTimeOnAndCountFile(setEnable, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetTimeOnAndCountFilePath Function returns the Time On And Count File Path.
- Returns a String containing the Time On And Count File Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
path = oasc.GetTimeOnAndCountFilePath(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine(path);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
path = oasc.GetTimeOnAndCountFilePath(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine(path)
End If
End Sub
End Class
End Namespace
- SetTimeOnAndCountFilePath Subroutine sets the Time On And Count File Path.
- Value is the desired value for Time On And Count File Path
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
oasc.SetTimeOnAndCountFilePath(path, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
oasc.SetTimeOnAndCountFilePath(path, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
GetEnableRetainTrendsFile
- GetEnableRetainTrendsFile Function returns Enable Trend File.
- Returns a Boolean, True for enabled, False for disabled.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool CurrentValue = oasc.GetEnableRetainTrendsFile(NetworkNode, ref ErrorString);
if (ErrorString == "Success")
{
if (CurrentValue)
{
Console.WriteLine("Enabled");
}
else
{
Console.WriteLine("Disabled");
}
}
else
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim CurrentValue As Boolean = oasc.GetEnableRetainTrendsFile(NetworkNode, ErrorString)
If ErrorString = "Success" Then
If CurrentValue Then
Console.WriteLine("Enabled")
Else
Console.WriteLine("Disabled")
End If
Else
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetEnableRetainTrendsFile Subroutine sets Enable Trend File.
- Value is the desired value for Enable Trend File.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
bool setEnable = false;
oasc.SetEnableRetainTrendsFile(setEnable, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim setEnable As Boolean = False
oasc.SetEnableRetainTrendsFile(setEnable, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- GetRetainTrendsFilePath Function returns the Retain Trends File Path.
- Returns a String containing the Retain Trends File Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = oasc.GetRetainTrendsFilePath(NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = oasc.GetRetainTrendsFilePath(NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
End If
End Sub
End Class
End Namespace
- SetRetainTrendsFilePath Subroutine sets the Retain Trends File Path.
- Value is the desired value for Retain Trends File Path.
- NetworkNode is the name of the network node of the OAS Service to connect to. Leave blank for localhost connection.
- Optional ErrorString will be set to Success when function is successful and an error message when in error.
C#
using System;
namespace OASDataSample
{
class Program
{
static OASConfig.Config oasc = new OASConfig.Config();
static void Main(string[] args)
{
string NetworkNode = "";
string ErrorString = "";
string path = "";
oasc.SetRetainTrendsFilePath(path, NetworkNode, ref ErrorString);
if (ErrorString != "Success")
{
Console.WriteLine(ErrorString);
}
else
{
Console.WriteLine(path);
}
}
}
}
VB
Imports System
Namespace OASDataSample
Class Program
Shared oasc As OASConfig.Config = New OASConfig.Config()
Public Shared Sub Main(ByVal args As String())
Dim NetworkNode As String = ""
Dim ErrorString As String = ""
Dim path As String = ""
oasc.SetRetainTrendsFilePath(path, NetworkNode, ErrorString)
If ErrorString <> "Success" Then
Console.WriteLine(ErrorString)
Else
Console.WriteLine(path)
End If
End Sub
End Class
End Namespace