iOS Question canOpenURL failing

iCAB

Well-Known Member
Licensed User
Longtime User
Hi There,

I am using Square mobile POS and I believe that this code was working before:


In main:
B4X:
#QueriesSchemes: square-commerce-v1

B4X:
#If ObjC
- (BOOL) checSquareInstalled {
     if ([[UIApplication sharedApplication]
        canOpenURL:[NSURL URLWithString:@"square://"]]) {   
        //canOpenURL:[NSURL URLWithString:@"square-commerce-v1://"]]) {   
        NSLog(@"square INSTALLED");
        return true;
    }
    else
    {
        return false;
    }

}
#End if


Now I am getting:

-canOpenURL: failed for URL: "square://" - error: "This app is not allowed to query for scheme square"

Any ideas?

Thanks
 
Last edited:
Top