cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
If you’ve changed your email address, now's the perfect time to update it on your Dropbox account and we’re here to help! Learn more 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: 

UIApplication sharedApplication methods for iOS 10

UIApplication sharedApplication methods for iOS 10

mrobinson
Helpful | Level 6
Go to solution

Hello,

 

The Documentation is Out for date for iOS 10 APIv2. It requires a completion handler.

 

Does anyone have this method in Objective-C?

 

 

#import <ObjectiveDropboxOfficial/ObjectiveDropboxOfficial.h>

- (void)myButtonInControllerPressed {
  [DBClientsManager authorizeFromController:[UIApplication sharedApplication]
                                 controller:self
                                    openURL:^(NSURL *url) {
                                      [[UIApplication sharedApplication] openURL:url];
                                    }
                                browserAuth:YES];
}

 

Thanks,

 

 

 

 

1 Accepted Solution

Accepted Solutions

mrobinson
Helpful | Level 6
Go to solution

Self Answered:

 

[DBClientsManager authorizeFromController:[UIApplication sharedApplication] controller:self openURL:^(NSURL *url) { [[UIApplication sharedApplication] openURL:url options:@{} completionHandler:^(BOOL success) {

        if (success) {

            NSLog(@"Opened url");

        }}

]; } browserAuth:YES];

 

 

View solution in original post

1 Reply 1

mrobinson
Helpful | Level 6
Go to solution

Self Answered:

 

[DBClientsManager authorizeFromController:[UIApplication sharedApplication] controller:self openURL:^(NSURL *url) { [[UIApplication sharedApplication] openURL:url options:@{} completionHandler:^(BOOL success) {

        if (success) {

            NSLog(@"Opened url");

        }}

]; } browserAuth:YES];

 

 

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    mrobinson Helpful | Level 6
What do Dropbox user levels mean?