Class Column (Outlook VBA)
The class Column represents a column of data in a Table object. To use a Column class variable it first needs to be instantiated, for example
Dim clm as Column
Set clm = AdvancedSearch.GetTable.Columns(Index:=1)
For Each
Here is an example of processing the Column items in a collection.
Dim clm As Column
For Each clm In AdvancedSearch.GetTable.Columns
Next clm
Class
Returns a constant in the OlObjectClass enumeration indicating the class of the Column object. Here you can find possible values for
Dim oocsClass As OlObjectClass
oocsClass = AdvancedSearch.GetTable.Columns(1).Class
Name
Returns a String value that represents the name of the Column.
The Name property is the default member of the Column object. If the Column is a default column in the Table, or if it has been added to the Table with the explicit built-in name for the property, the value of Name is the explicit built-in name (without any enclosing brackets) for the property. If the Column has been added to the Table with a property name referencing a namespace, the value of Name will be the property name referenced by namespace. For more information on referencing properties by namespace, see Referencing Properties by Namespace.
Dim strName As String
strName = AdvancedSearch.GetTable.Columns(1).Name
Session
Returns the NameSpace object for the current session.
The Session property and the Application.GetNamespace method can be used interchangeably to obtain the NameSpace object for the current session. Both members serve the same purpose. For example, the following statements perform the same function: