Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

When does isGooglePlayServicesAvailable return SERVICE_VERSION_UPDATE_REQUIRED?

Tags:

According to the documentation GooglePlayServicesUtil.isGooglePlayServicesAvailable returns SERVICE_VERSION_UPDATE_REQUIRED when "The installed version of Google Play services is out of date".

Does this mean that there is a new version of google play services in the play store?
Does this mean that the app needs a newer version than the one that is currently installed in the device?

How is this check done?

like image 670
pomber Avatar asked Feb 12 '15 14:02

pomber


1 Answers

this means that the version of google play service you included in your app is higher than the one currently installed on the users device. the user needs to update their google play services in-order for your app to work correctly.

if the result comes back with that error you can simply call this method to alert the user they need to update and it will take them there.

GooglePlayServicesUtil.getErrorDialog(result, this, GOOGLE_PLAY_SERVICE_UPDATE_CODE).show();

result is the result of the isGooglePlayServicesAvailable method

like image 76
tyczj Avatar answered Oct 04 '22 03:10

tyczj