APIGID32.DLL Library
</ol>
<span class="subheading">Our Review</span>
<span class="text">
While you can write VB applications without ever touching the API (in fact, that's what VB was originally for), the power of VB is that it can access the API to enhance its own functionality. Take, for instance, the Windows Registry. VB has some built-in functions that give you basic capabilities; however, you can access the appropriate API calls to get to the rest of the Registry. The problem with the API is that 1) it was written by and for C programmers, 2) the documentation is confusing and sometimes incorrect, and 3) it's hard to tell what the right API for the job is.
Dan Appleman, author of the VB Programmers' Guide to the Windows API, has come out with what is billed as a companion book to that monster book. The Win32 API Puzzle Book and Tutorial is a unique book designed to teach you how to use the API through a series of 32 puzzles. Each of these puzzles has a different problem, whether it is as simple as having the wrong API declaration, or as complex as an error because the bytes in the variable aren't lining up properly for the API call. Each of these puzzles covers a different section of the API and along the way, you'll pick up tips for using any of the 8000 API calls available in Windows.
As you can tell from the table of contents, this isn't your ordinary book. The first part has all 32 puzzles, each with a different scenario to fix. Dan hits a wide variety of APIs, including graphics, Registry, and even the Windows shell APIs for file and other operations. On a side note, it's good to see coverage of the shell APIs, which were left out of the other API guide he wrote. These APIs are extremely helpful, but can be extremely difficult to understand.
The second part of the book contains the solutions for the puzzles. Each of these solutions is written such that if you're looking for the code to do, say, a RAS connection, you can simply look at the solution to see the code in action. Of course, it's designed for you to try the puzzle first, but you can use the book as you see fit.
The third part of the book contains 11 tutorials on related topics. Some of these have appeared in various forms before on Dan's company web site and others are refined versions of industry best practices. They are helpful, even for expert programmers. In one of the tutorials covering the structure of the DLL, each of the pieces of the DLL are analyzed so that you can learn to open up any DLL to determine the functions within. This is a unique bit of teaching that I haven't seen before, and there are more tidbits like it in the book.
<span class="subheading">The Bottom Line</span>
<span class="text">
Like Dan's other book, this is an excellent one for you to keep on your shelf. Whether or not you use the specific APIs covered in the puzzles, the tutorials on how to really exploit the API are valuable material that you can't find in other books. Plus, you can always test your knowledge by trying to beat the puzzles that Dan has come up with.