dotConnect for FreshBooks Documentation
Devart.Common Namespace / DbConnectionBase Class / EndOpen Method
The System.IAsyncResult returned from BeginOpen.

In This Topic
    EndOpen Method
    In This Topic
    Ends an asynchronous invocation of the Open method.
    Syntax
    'Declaration
     
    Public Sub EndOpen( _
       ByVal result As IAsyncResult _
    ) 
    public void EndOpen( 
       IAsyncResult result
    )

    Parameters

    result
    The System.IAsyncResult returned from BeginOpen.
    Remarks

    BeginOpen method enables you to open a connection to server without having current thread blocked. In other words, your program can continue execution while the connection is establishing so you do not have to wait for it.

    To start opening a connection, you have to call BeginOpen method, which in turn invokes appropriate actions in another thread. Return value of this method must be assigned to System.IAsyncResult object. After executing this method program flow continues.

    When you are ready to use the connection, call EndOpen. If at the moment you call this method the negotiation process has not yet been finished, application stops and waits till the function returns which means that the connection is open.

    Refer to "Asynchronous Query Execution" article for examples and detailed information.

    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also