Foggy Bottoms has asked for the wisdom of the Perl Monks concerning the following question:

You probably know that Windows comes with a rather handy search dialog box that lets you search for a file containing a certain string. It's reasonably fast and convenient. I'd like to use that box in a perl program. So I started looking into Win32::API and Dave Roth's very useful Win32::API::Prototype.

However I'm having a lot of trouble calling the methods and making good use of the API functions. I know that what I'm looking for is included in comdlg32.dll. Has any monk had any experience in this field at all ? Is it even worth using Windows or would I be better off programming the search tool myself ?

Do you know where I can find a comprehensive reference of the methods included in the dll file ?

Many thanks, FG.

Edit by tye, title, paragraphs

Replies are listed 'Best First'.
Re: Win32 API - Windows search box
by gellyfish (Monsignor) on Jun 27, 2003 at 17:34 UTC

    The common dialog box reference is part of the Windows platform SDK which you can download from the MSDN website. You probably can find the same reference online here ( I say probably because these things seem to change as soon as you bookmark them )

    However having look at the local copy of said documentation that comes with visual studio - I can tell you that the document search is not part of that library - the find dialog is limited to the 'Find' that you get on the 'Edit' menu of windows applications.

    /J\
    
Re: Win32 API - Windows search box
by BrowserUk (Patriarch) on Jun 27, 2003 at 17:33 UTC

    To find out the names of the entrypoints in the dll, type quikview X:\winnt\system32\comdlg32.dll and page down to the "Export table".

    To get further info on the apis themselves and how to use them, try google. The information on the first hit at the codeproject looks pretty useful.

    MSDN usually turns up a reference for the API, but don't ignore stuff at other places, nor example code in VB/VBA, often these have better explainations of how to use the apis.

    Good luck.


    Examine what is said, not who speaks.
    "Efficiency is intelligent laziness." -David Dunham
    "When I'm working on a problem, I never think about beauty. I think only how to solve the problem. But when I have finished, if the solution is not beautiful, I know it is wrong." -Richard Buckminster Fuller


Re: Win32 API - Windows search box
by aquarium (Curate) on Jun 28, 2003 at 08:28 UTC
    there's a "Perl for Win32 book". i'm pretty sure that's the exact title, we've got it at work. so if you have no luck by monday/tuesday let me know and i'll dig up the info in the book.