IQueryCancelAutoPlay interface (shobjidl.h)
Exposes a method that programmatically overrides AutoPlay or AutoRun. This allows you to customize the location and type of content that is launched when media is inserted.
Inheritance
The IQueryCancelAutoPlay interface inherits from the IUnknown interface. IQueryCancelAutoPlay also has these types of members:
Methods
The IQueryCancelAutoPlay interface has these methods.
IQueryCancelAutoPlay::AllowAutoPlay Determines whether to play media inserted by a user and if so using what restrictions. |
Remarks
Note IQueryCancelAutoPlay is intended only for use by user-launched applications that are currently running. It should not be handled by invisible or background service applications to prevent the normal AutoPlay/AutoRun feature from being invoked. Giving the user a choice of what happens when media and devices are inserted into the system is a key feature of the platform. This feature is designed specifically to improve and personalize the user experience and should not be inhibited by background services.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | shobjidl.h |
See also
Autoplay in Windows XP: Automatically Detect and React to New Devices on a System