Connectivity Software User's Guide and Reference
ToString Method (VarType)



OpcLabs.BaseLibPrimitives Assembly > OpcLabs.BaseLib.ComInterop Namespace > VarType Class : ToString Method
Returns a System.String that represents the current VarType.
Syntax
'Declaration
 
<JetBrains.Annotations.NotNullAttribute()>
<JetBrains.Annotations.MustUseReturnValueAttribute()>
Public Overrides NotOverridable Function ToString() As String
'Usage
 
Dim instance As VarType
Dim value As String
 
value = instance.ToString()
[JetBrains.Annotations.NotNull()]
[JetBrains.Annotations.MustUseReturnValue()]
public override string ToString()
[JetBrains.Annotations.NotNull()]
[JetBrains.Annotations.MustUseReturnValue()]
public:
String^ ToString(); override 

Return Value

Returns the object contents expressed as readable string.

This method never returns null (Nothing in Visual Basic).

Remarks

If the value contains a VarTypes.Reserved, VarTypes.ByRef, VarTypes.Array or VarTypes.Vector flag (or their combination), the method returns the identifiers concatenated with a "|" operator.

This method or property does not throw any exceptions, aside from execution exceptions such as System.Threading.ThreadAbortException or System.OutOfMemoryException.

Requirements

Target Platforms: .NET Framework: Windows 10 (selected versions), Windows 11 (selected versions), Windows Server 2016, Windows Server 2022; .NET: Linux, macOS, Microsoft Windows

See Also