Share via


LobSystemInstance.OpenConnection Method

NOTE: This API is now obsolete.

Opens a connection to the business application with the connection parameters specified in the Business Data Catalog.

Namespace:  Microsoft.Office.Server.ApplicationRegistry.MetadataModel
Assembly:  Microsoft.SharePoint.Portal (in Microsoft.SharePoint.Portal.dll)

Syntax

'Declaration
<ObsoleteAttribute("O12 Application Registry API is deprecated. Please use BusinessData.",  _
    False)> _
Public Sub OpenConnection
'Usage
Dim instance As LobSystemInstance

instance.OpenConnection()
[ObsoleteAttribute("O12 Application Registry API is deprecated. Please use BusinessData.", 
    false)]
public void OpenConnection()

Remarks

Business Data clients can use two forms of connection management:

1. Explicit connection management

2. Implicit connection management

Explicit connection management is more complex but is useful and performant when sharing connections. For example, if three Business Data web parts want to share a connection to a backend and query it sequentially, implicit connection management would open and close a connection in each case. It is better to explicitly open a connection using LobSystemInstance.OpenConnection(), make the 3 Business Data Catalog object model calls from the 3 Business Data web parts and then close the connection. OpenConnection opens an explicitly managed connection and associates it with the current thread of control. OpenConnection should be used in conjunction with CurrentConnection - opening one only if CurrentConnection is NULL.

See Also

Reference

LobSystemInstance Class

LobSystemInstance Members

Microsoft.Office.Server.ApplicationRegistry.MetadataModel Namespace