MatchLost method

The MatchLost callback signals that an IWDTFTarget2 instance no longer matches the previously matched IMatchEventSource::SDEL statement


HRESULT MatchLost(
  [in]  IWDTFTarget2 *pTarget,
  [in]  IMatchEventSource *pSource


  • pTarget [in]
    The specific IWDTFTarget2 instance that no longer matches.

  • pSource [in]
    The specific IMatchEventSource instance that this event was sent from.

Return value

If you return an error (or throw an exception from script) while receiving the MatchLost callback, the first error will be saved and eventually returned from your call to IWDTFDeviceDepot2::UpdateAndReportMatches. Returning an error will not stop additional MatchLost and IMatchEvents::MatchFound callbacks from being sent.


You can enable the MatchLost event by calling IMatchEventSource::Start.

When the MatchLost event is sent, it means that an IWDTFTarget2 object was removed (or an existing one changed) so that it no longer matches the IMatchEventSource::SDEL statement that was specified when the IMatchEventSource instance was created.

You will not receive a MatchLost event for a given IWDTFTarget2/IMatchEventSource pair without first receiving the appropriate MatchFound event first.

You will not receive two MatchLost events for a given IWDTFTarget2/IMatchEventSource pair without receiving the appropriate MatchFound event between the two.

See also









Send comments about this topic to Microsoft

Build date: 3/12/2012