Anonymous
|
My first thought is why don't you use COM API to read all the databases? It's sort of the nice part of this business that you use high level access until you run out of options and only then switch to C API. Or is there some catch? Other than that I have little experience with callbacks. When I was writting the book I tested that in VB they work, still I got a feeling that there maybe some additional niceties -- in one sample I had to add some waiting time before it started working "properly". In any case all you need is to figure out how to declare callback function you provide in call to NSFSearch. I'd think something like this should work: Function NSFSEARCHPROC (EnumRoutineParameter as Long, SearchMatch As Long, ByVal SummaryBuffer As Long) as Integer ... End Function The last parm is a pointer to the structure, so I think for starters you'd rather get it by value and then read the structure. Or maybe you can make VB to read right in the structure by declaring: SummaryBuffer As ITEM_TABLE) Then when you call NSFSearch you provide "AddressOf NSFSEARCHPROC" as an argument. Should be all that simple /to give advice;-/ Let me know how this worked out.
|