Get th lat and lon using address
- by sairam333
Hi I use below code for getting the lattitude and longitude Using the given address 
try {
                  List<Address> foundAdresses = gc.getFromLocationName(addressInput, 5); //Search addresses
                 for (int j = 0; j < foundAdresses.size(); ++j) {
                      //Save results as Longitude and Latitude
                      //@todo: if more than one result, then show a selected-list
                      Address x = foundAdresses.get(j);
                        lat = x.getLatitude();
                        lon = x.getLongitude();
                    } 
                }
            catch(Exception e)
            {
}
But the above code does not return any values into lat,lon(double variables),
and i sue the uses-permissions in android manifest file also
But the lat,lon variables does not getting any values.Please give me some suggestions.Thanks in advance.