Home > other >  Call Win32 DeviceWatcher API from Dynamic Link Library
Call Win32 DeviceWatcher API from Dynamic Link Library

Time:08-03

I create a DLL project in VS 2022. How is it possible to add a call to the Win32 DeviceWatcher API?

I need to add this to use it:

using namespace Windows::Devices::Enumeration;
using namespace Windows::Foundation

But where must I add references to the Win32 API?

CodePudding user response:

The DeviceWatcher Class is Windows Runtime API. I suggest you should create a Windows Runtime component DLL or class library universal windows.

For more details I suggest you could refer to the Doc: DLLs

  • Related