You need to sign in to do that
Don't have an account?
Hüsna Çuhadaroğlu
VisualForce Pages return problem
After Lightning release, our visualforce pages ,in Salesforce1, which is connected to Opportunity, are not closing safely.
The code block is;
pr = new PageReference('/' + oppId);
pr.getParameters().put('nooverride', '1');
pr.getParameters().put('id', oppId);
return pr.setRedirect(true);
In this block return pr.setRedirect(true); is not useful for returning to opportunity anymore.
We're getting this problem on production environment.
Is there anyone have the same problem? How can we handle with this bug?
The code block is;
pr = new PageReference('/' + oppId);
pr.getParameters().put('nooverride', '1');
pr.getParameters().put('id', oppId);
return pr.setRedirect(true);
In this block return pr.setRedirect(true); is not useful for returning to opportunity anymore.
We're getting this problem on production environment.
Is there anyone have the same problem? How can we handle with this bug?
You should change your code as below : It will work in the same manner as you are trying to do with your method.
Please try with this and let me know if you have any issue.
Thanks,
Abhishek
Can you tell us the error that you are getting in using the above code.
If there is no error than what is the actually happening here.
Can you please let us know the behaviour of this code ?
It would be easy to help you out if you can contact me on my gmail or skype.
Gmail : abhibansal2790@gmail.com
Skype : abhishek.bansal2790
Thanks,
Abhishek
This code block is a kind of redirecting the visualforce page to the right page. But with our code and the other one which is sent by you, didn't work for returning. This happened after winter release.
if( (typeof sforce != 'undefined') && (sforce != null) ) { // Salesforce1 Remote Action method built in controller } else { //Action Function of normal App }
Let me know if you need any further help on this.
Please mark a Best Answer to close this thread.
Your code didn't work on our vf pages. We're trying to find another ways but really thanks for helps.
I think you are also invoking a action method on commandbutton, that case try this variation of the code
I've also removed the console.log statements from the javascript a they do not work in IE.
Let me know if you need any further help on this.
Please try this code in your apex code which will return a Standard Visualforce Page.
Hope this answer your question.
Regards,
TabreZ
Please mark a Best Answer to close this thread.
https://developer.salesforce.com/forums/ForumsMain?id=906F00000005I83IAE