SmsOpenFilterContainer

The SmsOpenFilterContainer function opens a filter container and populates the filter container with persistent filters. Currently, SMS queries (persistent machine filters) are the only type of persistent filter. SmsOpenFilterContainer returns the handle to the filter container in the phFContainer parameter.

SMS_STATUS SmsOpenFilterContainer(
  HANDLE hConnection,  // Handle to database connection.
  HANDLE *phFContainer // Receives handle to the filter container.
);
 

Parameters

hConnection
Specifies the handle to the database connection. A database connection is established by using SmsDataSourceConnect.
phFContainer
Points to the handle that will receive the handle to a filter container.

Return Values

The SmsOpenFilterContainer function returns a status code SMS_STATUS. If successful, the function returns a status of SMS_OK. Otherwise, it returns the following manifest constant:

SMS_INVALID_HANDLE
The attempt to open the filter container failed.

Remarks

After your application has finished using a filter container, it should free the memory used by the filter container by calling the SmsCloseFilterContainer function.

See Also

SmsDataSourceConnect, SmsCloseFilterContainer