FlorentBl Posted July 21, 2011 Share Posted July 21, 2011 Bonjour, Je cherche le moyen d'obtenir la position du téléphone une seule fois. Malheureusement, sur tous les tutoriels, on ne peux obtenir la position que lors d'une mise à jour de celle ci. J'ai essayé cette manière : Location loc = new Location(providers.get(0)); ((TextView)findViewById(R.id.latitude)).setText(""+loc.getLatitude()); ((TextView)findViewById(R.id.longitude)).setText(""+loc.getLongitude()); Pourriez vous m'aider ? d'avance merci :). F. Edit : en résumé, c'est comment obtenir la position du mobile sans passer par la méthode requestLocationUpdates ? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.