在无法检索位置(gps位置)点(纬度和经度)之后,如何在条件和应用程序的打开页面需要相同后停止所有下一个进程(代码)(即, app不得关闭。)
if(provider!=null && !provider.equals("")){
// Get the location from the given provider
Location location = locationManager.getLastKnownLocation(provider);
locationManager.requestLocationUpdates(provider, 20000, 1, this);
if(location!=null)
onLocationChanged(location);
else
Toast.makeText(getBaseContext(), "Location can't be retrieved", Toast.LENGTH_SHORT).show();
}else{
Toast.makeText(getBaseContext(), "No Provider Found", Toast.LENGTH_SHORT).show();
}
当第一个其他人到达应用程序中的所有其他进程时,需要停止并且需要打开一个警告框,但该应用程序不能退出。
需要打开应用页面。