Forum Discussion

fazalabbas's avatar
fazalabbas
Explorer | Level 3
5 years ago

how to upload image form picturebox to dropbox using api C#

Hi guys i am using dropbox api for uploading image .it works fine when i give location of image form drives.but i want to upload image form picturebox which i m using in winform app (C#).

 

please anybody help me.

  • Greg-DB's avatar
    Greg-DB
    Icon for Dropbox Staff rankDropbox Staff

     

    I'm not sure I understand your question. Can you add some more context, e.g., show what you have so far, and let us know what's not working?

     

    For C#, we recommend using the official Dropbox API v2 .NET SDK if you can. With that, you can upload files using the upload methods, such as UploadAsync. You supply a Stream of the file data to upload to the 'body' parameter. Exactly where you get that Stream from is up to you. There's an example of using that method here.

     

    If you're having trouble getting something working, the following can be helpful:

     

    • the name and version number of the platform and SDK/library you are using, if any
    • the steps to reproduce the issue, including relevant code snippet(s)
    • the full text of any error or unexpected output