Connectivity Software User's Guide and Reference
_OpcBrowseDialog Interface
Members  Example 



OpcLabs.EasyOpcForms Assembly > OpcLabs.EasyOpc.Forms.Browsing.ComTypes Namespace : _OpcBrowseDialog Interface
Exposes OpcLabs.EasyOpc.Forms.Browsing.OpcBrowseDialog to COM clients.
Object Model
_OpcBrowseDialog InterfaceEasyAEClientSelector ClassEasyDAClientSelector ClassOpcBrowseInputs ClassOpcBrowseInputsOutputs ClassOpcBrowseMode ClassOpcBrowseOutputs Class
Syntax
'Declaration
 
<CLSCompliantAttribute(False)>
<ComVisibleAttribute(True)>
<GuidAttribute("0AA07238-D0EB-44A6-B1A4-C18F6BF4DE44")>
<InterfaceTypeAttribute(ComInterfaceType.InterfaceIsDual)>
Public Interface _OpcBrowseDialog 
'Usage
 
Dim instance As _OpcBrowseDialog
[CLSCompliant(false)]
[ComVisible(true)]
[Guid("0AA07238-D0EB-44A6-B1A4-C18F6BF4DE44")]
[InterfaceType(ComInterfaceType.InterfaceIsDual)]
public interface _OpcBrowseDialog 
[CLSCompliant(false)]
[ComVisible(true)]
[Guid("0AA07238-D0EB-44A6-B1A4-C18F6BF4DE44")]
[InterfaceType(ComInterfaceType.InterfaceIsDual)]
public interface class _OpcBrowseDialog 
Remarks

This member or type is for use from COM. It is not meant to be used from .NET or Python. Refer to the corresponding .NET member or type instead, if you are developing in .NET or Python.

Example

COM

// This example shows how to let the user browse for an OPC Data Access node.
//
// Find all latest examples here: https://www.doc-that.com/files/onlinedocs/OPCLabs-ConnectivityStudio/Latest/examples.html .
// OPC client and subscriber examples in Object Pascal (Delphi) on GitHub: https://github.com/OPCLabs/Examples-ConnectivityStudio-OP .
// Missing some example? Ask us for it on our Online Forums, https://forum.opclabs.com/forum/index ! You do not have to own
// a commercial license in order to use Online Forums, and we reply to every post.

class procedure ShowDialog.Main;
var
  BrowseDialog: OpcLabs_EasyOpcForms_TLB._OpcBrowseDialog;
begin
  // Instantiate the dialog object
  BrowseDialog := CoOpcBrowseDialog.Create;

  BrowseDialog.ShowDialog(nil);

  // Display results
  WriteLn(BrowseDialog.Outputs.CurrentNodeElement.DANodeElement.ToString);
end;
Rem This example shows how to let the user browse for an OPC Data Access node.
Rem
REM Find all latest examples here: https://www.doc-that.com/files/onlinedocs/OPCLabs-ConnectivityStudio/Latest/examples.html .
REM OPC client and subscriber examples in Visual Basic on GitHub: https://github.com/OPCLabs/Examples-ConnectivityStudio-VB .
REM Missing some example? Ask us for it on our Online Forums, https://forum.opclabs.com/forum/index ! You do not have to own
REM a commercial license in order to use Online Forums, and we reply to every post.

Private Sub ShowDialog_Main_Command_Click()
    OutputText = ""

    ' Instantiate the dialog object
    Dim browseDialog As New OpcBrowseDialog
    Dim DialogResult
    DialogResult = browseDialog.ShowDialog
    
    OutputText = OutputText & DialogResult & vbCrLf
    If DialogResult <> 1 Then   ' OK
        Exit Sub
    End If
    
    ' Display results
    OutputText = OutputText & browseDialog.Outputs.CurrentNodeElement.DANodeElement & vbCrLf
End Sub
Rem This example shows how to let the user browse for an OPC Data Access node.
Rem
Rem Find all latest examples here: https://www.doc-that.com/files/onlinedocs/OPCLabs-ConnectivityStudio/Latest/examples.html .
Rem OPC client and subscriber examples in VBScript on GitHub: https://github.com/OPCLabs/Examples-ConnectivityStudio-VBScript .
Rem Missing some example? Ask us for it on our Online Forums, https://forum.opclabs.com/forum/index ! You do not have to own
Rem a commercial license in order to use Online Forums, and we reply to every post.

Option Explicit

Const DialogResult_OK = 1

Dim BrowseDialog: Set BrowseDialog = CreateObject("OpcLabs.EasyOpc.Forms.Browsing.OpcBrowseDialog")
Dim dialogResult: dialogResult = BrowseDialog.ShowDialog
WScript.Echo dialogResult

If dialogResult <> DialogResult_OK Then
    WScript.Quit
End If

' Display results
WScript.Echo BrowseDialog.Outputs.CurrentNodeElement.DANodeElement
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