ExternalConnectionCollection Class

Specifies the ExternalConnection collection
Inheritance Hierarchy
SystemObject
  System.CollectionsCollectionBase
    Aspose.Cells.ExternalConnectionsExternalConnectionCollection

Namespace:  Aspose.Cells.ExternalConnections
Assembly:  Aspose.Cells (in Aspose.Cells.dll) Version: 21.7.0.0 (21.7)
Syntax
public class ExternalConnectionCollection : CollectionBase

The ExternalConnectionCollection type exposes the following members.

Properties
Methods
  NameDescription
Public methodClear (Inherited from CollectionBase.)
Public methodEquals (Inherited from Object.)
Protected methodFinalize (Inherited from Object.)
Public methodGetEnumerator (Inherited from CollectionBase.)
Public methodGetExternalConnectionById
Gets the ExternalConnection element with the specified id.
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Protected methodOnClear (Inherited from CollectionBase.)
Protected methodOnClearComplete (Inherited from CollectionBase.)
Protected methodOnInsert (Inherited from CollectionBase.)
Protected methodOnInsertComplete (Inherited from CollectionBase.)
Protected methodOnRemove (Inherited from CollectionBase.)
Protected methodOnRemoveComplete (Inherited from CollectionBase.)
Protected methodOnSet (Inherited from CollectionBase.)
Protected methodOnSetComplete (Inherited from CollectionBase.)
Protected methodOnValidate (Inherited from CollectionBase.)
Public methodRemoveAt (Inherited from CollectionBase.)
Public methodToString (Inherited from Object.)
Examples
[C#]
Workbook wb = new Workbook("connection.xlsx");
ExternalConnectionCollection dataConns = wb.DataConnections;
ExternalConnection dataConn = null;
for (int i = 0; i < dataConns.Count; i++)
{
    dataConn = dataConns[i];
    //get external connection id
    Console.WriteLine(dataConn.ConnectionId);
}

[Visual Basic]
Dim wb As Workbook = New Workbook("connection.xlsx")
Dim dataConns As ExternalConnectionCollection = wb.DataConnections
Dim dataConn As ExternalConnection
Dim count As Integer = dataConns.Count - 1
Dim i As Integer
For i = 0 To count Step 1
    dataConn = dataConns(i)
    'get external connection id
    Console.WriteLine(dataConn.ConnectionId)
Next
See Also