You need to sign in to do that
Don't have an account?

From Opportunity Wizard - On Save send user to standard Add Products page
Very similar to the VF Cookbook Opportunity Wizard example, I have created an opportunity creation wizard because my users complain about too many clicks when creating an opportunity, adding products, etc. My question is when the user clicks on Save, I would like to save the opportunity but instead of redirecting to the saved opportunity detail, go directly to the standard add products page. I do not want to add the button to the VF page, just redirect to the standard add products search functionality.
I have been trying to set the addProductsURL as the page reference after saving the opportunity and have tried it a couple of ways in my controller without success.
public PageReference addProductsURL(){ PageReference p = new PageReference('/'+SelectSearch?addTo={!Opportunity.ID} ); p.getParameters().put('addTo',opportunity.Id); p.setRedirect(true); return p; This is how I tried to return the addProductsURL after saving opportunity: PageReference addProduct = Page.addProductsURL; addProduct.getParameters().put('id',this.controller.getId()); addProduct.setRedirect(true); return addProduct;
Thanks! Any ideas are appreciated :)
Hi,
Were you able to do this ?, please share if you have solution.
Thanks a ton in advance!
Yes, I was able to do this.