You need to sign in to do that
Don't have an account?
Ola Bamidele
Does any one know why this code isnt saving?
Hi everyone,
I have this code for be able to display leads on a map with the distance away from you.
However for me, it isnt savibg for some reason that I cant see, can anyone see what i am doing wrong please?
This is my code:
Thanks very much
I have this code for be able to display leads on a map with the distance away from you.
However for me, it isnt savibg for some reason that I cant see, can anyone see what i am doing wrong please?
This is my code:
public with sharing class LeadVisualiserSSController { @AuraEnabled public static List<Lead> getLeads() { return [ SELECT Id, Name, Latitude, Longitude FROM Lead WHERE OwnerId = :UserInfo.getUserId() AND Latitude != NULL AND Longitude != NULL ]; } @AuraEnabled public static User getUserInfo() { return [ SELECT Id, Name, Base_Location__Latitude__s, Base_Location__Longitude__s FROM User WHERE Id = :UserInfo.getUserId() ]; } }
Thanks very much
I have tried to save this code in my developer org and is saved without any issue.
please let us know what issue you are facing.
Thanks
Hemant
The error that i am getting is:
I have tried changing the __s to __c but still isnt working, do you know why by any chance?
Thanks very much.
Thanks
The field name in Salesforce is "Base_location__c" so i changed it to that but still getting an error saying
Do you know why this is? THanks very much for the suggestions
Did you provide all necessary Permission to this field may this field doesn't have sufficient access.Please Check.
Thanks
This might help people fix your problem faster.
All necessary Permission are enable so the field must have sufficient access. So it very weird that your one is working by my one isnt
Thanks
My new code is the same as any changes I have made has not worked unfortunately:
Also, my API Name is:Base_location__c and the field label is Base location.
Thanks for the response
This is the code that I am trying to save. I am trying to save it into my Salesforce developer console and its not saving. Has that cleared it up more?
Thanks
It isn't possible to help fix the problem that gave you that error without seeing the code that mentions Base_Location__c - does that make sense?