This document is archived and information here might be outdated.  Recommended version.

IDataLayer.Connect Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Carto > ESRI.ArcGIS.Carto > Interfaces > ID > IDataLayer Interface > IDataLayer.Connect Method
ArcGIS Developer Help

IDataLayer.Connect Method

Connects the layer to its data source. An optional name object can be specified to aid in repairing a lost connection.

[Visual Basic .NET]
Public Function Connect ( _
    ByVal pOptRepairName As IName _
) As Boolean
public bool Connect (
    IName pOptRepairName
HRESULT Connect(
  IName* pOptRepairName
pOptRepairName [in]

pOptRepairName is a parameter of type IName*

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

See Also

IDataLayer Interface