We have number of vf page there we have method in apex class to navigate, Now we are moving to support our app for lightning experience. so we have updated the number of pages with sforce.one.back() method in pagerefrence javascript (pageReference('JavaScript:sforce.one.back();')) to navigate. It was working before summer 16, now it's seems like not working after summer 16 updates. It's work if we used sforce.one.back() method in vf page but it's very big issue for us because we have used pageReference to all the place to navigate.

Sample VF page

<apex:page controller="testSforceOne" id="page">
    <apex:commandLink action="{!goBack}"  reRender="page">Click here to Go Back</apex:commandLink>

Sample controller

   public class testSforceOne {
        public pageReference goBack(){
         return new PageReference('javascript:sforce.one.back();');

Lightning Inspector log. enter image description here

  • Can you check the sforce reference is valid by doing something like if( (typeof sforce != 'undefined') && (sforce != null) ) { – Gaurav Kheterpal Jun 15 '16 at 14:36
  • What you're stating is very unclear to me. Where is this not working? Is it not working in mobile pages, Lightning Desktop, or Visualforce desktop pages? – crmprogdev Jun 15 '16 at 14:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.