Is there a way to find out if the iPhone / iPad app is already installed?

I am writing a free version of the application and want to check if the user already has a non-free version installed, and print a message whose contents depend on the results of the installation check ... does anyone know if this is possible?

The closest I came to a decision was to use the CFPreferencesSetValue API with kCFPreferencesAnyUser / kCFPreferencesCurrentHost pairing ... I have not tried it, but based on the documentation it seems possible.

however, in my specific situation, this API will not be able to solve my problem because I want to check for an application that I wrote 4 months ago that did not write any data to the CFPrefs registry ... because at that time I did not know about it and did not foresee the situation ... the only way CFPrefs can help me is in future applications now that I know that it exists :)

so I wonder if there are other ways to do this? any help would be appreciated :)

+3
source share
5 answers

URL , canOpenURL , , .

+6

, , . , wild-card , . .

+3

. .

0

, , .

, , . , .

if( [[UIApplication SharedApplication] canOpenURL:(the apps scheme)] )
{
NSLog(@"App found");
}

.

json api .

http://schemes.zwapp.com/

http://schemes.zwapp.com/.json?page=1 http://schemes.zwapp.com/.json?page=470 .

.

http://handleopenurl.com/

https://github.com/danielamitay/iHasApp

0

Sorry, no, there is no way for the application to find out information about any other application installed on the iPhone (without jailbreaking). Apple intentionally isolates applications so that they are completely isolated.

The best thing you could do (in the future) is to register a URL handler that will launch your other application and, in turn, will launch your current application with the parameter.

-Dan

-1
source

Source: https://habr.com/ru/post/1748402/


All Articles