cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to know all about tools for creatives that work seamlessly with Dropbox, like Adobe? Well, check it out right here!

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

listFolder: returns hasmore in a directory with only 2 files

listFolder: returns hasmore in a directory with only 2 files

Kyri
Explorer | Level 4

Hi, I am experiensing this issue very often

it happens in the following scenario:

you have let's say 150 files

149 appear with simple listFolder

and one is not listed

then move all the 149 files and only leave the one that was not listed

and add one more

when you call 

listFolder: again it will only return 1 file

and hasMore will be TRUE

Any ideas how I can force list folder to always return all files in the directory?

(objC api)

Kind regards.

4 Replies 4

Re: listFolder: returns hasmore in a directory with only 2 files

Kyri
Explorer | Level 4

Has more  & listFolderContinue

returns the new item(s)

 

but I was wondering how do I "reset it" if you will

Re: listFolder: returns hasmore in a directory with only 2 files

Здравко
Super Collaborator | Level 20

Hi @Kyri,

Actually you can't. The call is asynchronous and the bechaviour can't be predicted or forced. You should always check for 'has_more' flag set and get in loop until flag gets unset.

Hope this helps.

Re: listFolder: returns hasmore in a directory with only 2 files

Kyri
Explorer | Level 4

Thanks for the feedback Здравко

Re: listFolder: returns hasmore in a directory with only 2 files

Greg-DB
Dropboxer

Здравко is correct, you can't force or predict this. You need to always check hasMore and call back if needed. For reference, you can find the corresponding documentation for the Objective-C SDK in particular under listFolder and listFolderContinue.

Poll
Do you work or study in the creative industry? If so, which area?
If you use Adobe, don't forget to check out our latest integrations update here.
Who's talking

Top contributors to this post

  • User avatar
    Greg-DB Dropboxer
  • User avatar
    Kyri Explorer | Level 4
  • User avatar
    Здравко Super Collaborator | Level 20
What do Dropbox user levels mean?
Need more support?