This has to be an easy question. I've never been able to figure out how to use interfaces in Visual C++. I have some sample code that uses the IActiveDesktop interface (the one I want to use) but I don't know what .h files etc. to include to make it compile. Here's the sample code:
//Create an instance of the Active Desktop
hr = CoCreateInstance(CLSID_ActiveDesktop, NULL, CLSCTX_INPROC_SERVER,
//Insert code to call the IActiveDesktop methods
pActiveDesktop->GetWallpaper(sWallpaper, 256, 0);
// Call the Release method
I simply stuck the code in the OnInitDialog() of my dialog-based AppWizard app.
Any help is much appreciated! TIA.