Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [geolocation]

The Geolocation field type allows for SOQL queries based on location and distance. Functions DISTANCE and GEOLOCATION support distance and location-based SOQL queries.

28
votes
1answer
3k views

What formulae does the Geolocation Distance use?

Forgive me if this is a bit extremely academic in nature, but I was wondering how Salesforce goes about determining the distance between two pairs of latitude and longitude? When I've looked at this ...
10
votes
3answers
5k views

can geolocation fields be used to calculate and display distance?

I have a geolocation field setup on an object and want to be able to display the distance from another location in miles on a Visualforce page. I see with the new geolocation fields you can use ...
3
votes
1answer
277 views

Is it possible edit Geolocation custom field in Inline mode?

I have custom field Location of Geolocation type for standard objects (Account, Contract, Lead etc). For example, I want this field to be editable. On Edit Layout it is editable by default. But ...
10
votes
3answers
3k views

Geolocation searching

I'm researching location search (ultimately on a Force.com site). For example's sake, the problem is to dynamically show a user what stores are w/in a certain distance (say miles) of a postal code ...
1
vote
1answer
605 views

Geolocation with LockerService

A simple code getting current user geolocation is strangely ... ignored: it doesn't go to the success callback, neither in the error callBack, so I really have no idea of the cause. As window....
3
votes
1answer
2k views

Enable VisualForce Map Component apex:map

I have found to my delight that there is now a standard map component. However, it is apparently not enabled for my org. How do I enable them? Is this feature still in beta? All the listed features ...
3
votes
3answers
790 views

Getting Lat and Long in SalesForce

I'm new to SalesForce and I'm working on an app that requires me to calculate distance between two given addresses. User enters 2 addresses and then I calculate the distance between those two ...
3
votes
1answer
4k views

How to display Location part of Address field type

Is there any way to display Geolocation part of Address field type in edit or display mode? Account object contains specific BillingAddress field of Address type (is in beta). Also, as mentioned here,...
7
votes
1answer
6k views

Are latitude and longitude saved automatically?

I'm wanting to use the BillingLatitude and BillingLongitude fields attached to my Account object in a workflow rule, but I can't seem to get them to work. I pulled an export via Data Loader of the ...
4
votes
1answer
325 views

Access DISTANCE SOQL Result in Visualforce

I am trying to access the result of a DISTANCE SOQL Query in visualforce but I cannot figure out how to do this. The correct values do appear in debugging. Below is my relevant code: Controller: ...
1
vote
2answers
1k views

navigator.geolocation.getCurrentPosition fails in Visualforce page

I ran into a rather bizarre issue today with the HTML5 Geolocation API. I'm working one a Visualforce page in Salesforce1 that grabs the user's current location and passes it up to an Apex Controller ...
1
vote
1answer
87 views

App error After restarting the device

I am using Et SDK 3.5.0, After I enabled the Geofence feature on the app, it will generate an error after restarting the device and opening the app. E/ERROR>>>﹕ Initialization did not ...
1
vote
1answer
452 views

Geo location not visible

Hi I have used the below code but the map not showing in visualforce page. Code: <apex:page> <html> <head> <title>Geolocation</title> <style> ...
0
votes
3answers
559 views

Getting lat/lng for person accounts

Based on my understanding the mailing address on a person account will not be auto geolocated as is the case with normal accounts. What is the easiest way to get a lat/lng for a person account? I ...