Upravit

Sdílet prostřednictvím


Search.GetTable Method

Definition

Obtains a Table object that contains items filtered by the Filter parameter in a preceding AdvancedSearch(String, Object, Object, Object) method call.

public:
 Microsoft::Office::Interop::Outlook::Table ^ GetTable();
public Microsoft.Office.Interop.Outlook.Table GetTable ();
Public Function GetTable () As Table

Returns

A Table that contains items that meet the criteria specified by the Filter parameter in a preceding Application.AdvancedSearch method call.

Remarks

Unlike GetTable(Object, Object), Search.GetTable does not accept a Filter parameter. The filter for the Table is determined by Filter. Since Search.Filter is a read-only property, the Filter parameter for the Application.AdvancedSearch method establishes the filter for the Table object returned by Search.GetTable.

The Filter parameter supplied to Application.AdvancedSearch must be a DASL query. The filter for AdvancedSearch will not accept a JET query. Do not prefix a DASL query for AdvancedSearch with “@SQL=”. If you add the “@SQL=” prefix, your query will raise an error. For more information on filters, see Filtering Items

Search.GetTable returns a Table with the default column set for the folder type of the parent Folder. To modify the default column set, use the Add(String), Remove(Object), or RemoveAll() methods of the Columns collection object. For more information on default column sets, see Default Properties Displayed in a Table Object

Unlike Folder.GetTable, you cannot use Restrict(String) to apply subsequent filters to a Table that is based on the Search object. Specify a new filter in Application.AdvancedSearch to re-apply a filter.

Applies to