You need to sign in to do that
Don't have an account?
Veronika Ivhed
Redirect to VF page on save opportunity. Record type selection is shown twice.
Hi,
I am trying to override the New button on Opportunity with the following Visualforce Page:
<apex:page standardController="Opportunity">
<script>
window.top.location.replace("{!URLFOR($Action.Opportunity.New, null, [saveURL='/apex/RedirectToCompetitorAgreement',nooverride=1,save=1], true)}");
</script>
</apex:page>
When the user has entered the opportunity information and presses save he is redirected to the VF page "RedirectToCompetitorAgreement". Everything works as expected except that the record type selection page is shown two times. Any ideas on how I can fix this issue?
I am trying to override the New button on Opportunity with the following Visualforce Page:
<apex:page standardController="Opportunity">
<script>
window.top.location.replace("{!URLFOR($Action.Opportunity.New, null, [saveURL='/apex/RedirectToCompetitorAgreement',nooverride=1,save=1], true)}");
</script>
</apex:page>
When the user has entered the opportunity information and presses save he is redirected to the VF page "RedirectToCompetitorAgreement". Everything works as expected except that the record type selection page is shown two times. Any ideas on how I can fix this issue?
Use retUrl to return your desired location, as below line is leads to opportunity detail page.
Let us now if it helps.
For record type selection in page, you have to check your profile, default record type.
u have to select only one record type as default for the profile. then it will redirect to your corresponding pagelayout based on your page layout assignment for the record type.
-- Suma.
this is for ur ref.
-- Suma .
Having one default record type will not solve my issue since I want the users to be able to select from two different record types.
/Veronika
I am having same issue , how did you solve your problem?
Thanks,
Raghu