--- Carmen Sandiego <[EMAIL PROTECTED]> wrote:
> The following code is from a Palm OS book.  I am using 
> this to determine the total number of databases stored 
> with a particular creator ID & type.
> 
> if (DmGetNextDatabaseByTypeCreator(true, &searchState, 
>    myType, myCreator, false, &cardNo, &dbID)
> {
>   do {
>      count++
>   } while (DmGetNextDatabaseByTypeCreator(false, 
>       &searchState, myType, myCreator, false, &cardNo, &dbID);
> }
> 

This code looks wrong.  DmGetNextDatabaseByTypeCreator() returns
errNone (0) if there is no error, and it returns 

> What does DmGetNextDatabaseByTypeCreator return?  Does it only return
> a
> value (dmErrCantFind) when no more of my databases are found?  If so,
> how
> does this algorithm work?  Will it ever go into the loop if
> DmGetNextDatabaseByTypeCreator only returns a value when no more
> databases
> are found?  (i.e.  The if statement will never be true?)
> 
> 
> -- 
> For information on using the Palm Developer Forums, or to
> unsubscribe, please see http://www.palmos.com/dev/support/forums/


__________________________________________________
Do You Yahoo!?
Yahoo! Movies - coverage of the 74th Academy Awards�
http://movies.yahoo.com/

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to