Reputation: 65
i created some code to get a folder from box.NET using the method GetFolder( ) of the CloudStorage object. but when i ran it gave a NullReferenceExeption and i dont know what is the problem. the code work fine for Dropbox. by the way there is no problem with Box.NET credential since i managed to successfully open the connection to Box.NET.
Any help will be appreciated
Upvotes: 0
Views: 451
Reputation: 41
If you're still looking into the problem, I just had to debug it myself.
I kept overlooking the problem as the goof is so minor, but check out BoxNetStorageProviderServices.cs
.
OnNameBase
assumes a url will arrive as http
rather than https
. The string replace then changes the url from https://www.box.com/dav/blahblah
to httpss://www.box.com/dav/blahblah
.
After adding a tiny bit of logic, everything works great.
Upvotes: 4
Reputation: 2599
Which library are you using? There is a Box C# library that Box provides the basic tools to get you using the Box apis: https://github.com/box/box-csharp-sdk
You will also get more help from a broader Box community if you tag this question with the box-api tag.
Upvotes: 1