You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

brtdvrs's avatar
brtdvrs
Explorer | Level 4
2 years ago

cannot get list of files .NET

I think my code is simple:

string token = "sl.<REDACTED>";

 

var dbx = new DropboxClient(token);

var res = await dbx.Files.ListFolderAsync(path: "");
foreach (var entry in res.Entries)
{
Console.WriteLine(entry.Name);
}

if have no entries (Count=0) here.

I have 4 folders and 1 file in in my dropbox folder. 

  • brtdvrs As Здравко said, you may have registered your app for "app folder" access, in which case it would only be able to access the contents of the special app folder that gets created for it automatically. You can find more information here. App folders are empty by default.

  • Здравко's avatar
    Здравко
    Legendary | Level 20

    Hi brtdvrs,

    Does your application able to access your entire account or access only your App' folder only? 🧐 If the access is restricted, your can't see anything outside your App's folder! Recreate the application if you set it's access restricted by mistake. 😉

     Hope this gives direction.

    • brtdvrs's avatar
      brtdvrs
      Explorer | Level 4
      I have it restricted to App folder, so I created a folder with the same name on my Dropbox, that’s the way to do i guess ?
  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

    brtdvrs As Здравко said, you may have registered your app for "app folder" access, in which case it would only be able to access the contents of the special app folder that gets created for it automatically. You can find more information here. App folders are empty by default.

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,910 PostsLatest Activity: 3 days ago
333 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!