Header/Lib files for CM_Request_Device_Eject

Posted on 2005-05-15
Last Modified: 2013-11-17
I wish to use the  win api function  :-

    IN DEVINST  dnDevInst,
    OUT PPNP_VETO_TYPE  pVetoType,
    OUT LPTSTR  pszVetoName,
    IN ULONG  ulNameLength,
    IN ULONG  ulFlags

I cannot find which header file(s) or DLL(s) to use wit borland C++ builder 5.0 ?

Can anyone help ? The Windows programming section doesn't have a C++ Builder section which is why I have posted this question here.

Thanks in advance,


Question by:alcindor
    LVL 16

    Expert Comment

    by:George Tokas
    Check out here:

    Its the documentation about the command... As I read there you want to programmatically want to safe remove a usb (pnp) device...
    The headers and explaination is there...

    LVL 16

    Accepted Solution

    cfgmgr32.dll must be located at your Windows\system directory..
    The call of the function reffered to this.
    An (easy) way is to use implib and impdef to this dll to create an interface to this dll and call the function.


    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Programmer's Notepad is, one of the best free text editing tools available, simply because the developers appear to have second-guessed every weird problem or issue a programmer is likely to run into. One of these problems is selecting and deleti…
    Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project ( automates most of the tasks discussed in this article. You can even fin…
    The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
    The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    24 Experts available now in Live!

    Get 1:1 Help Now