1

I have created a custom create button since we cannot define a lookup value with an action. I have created the button, but when I go to test it states that the URL no longer exists. I copied the url from the standard create button:

https://cs54.salesforce.com/setup/ui/recordtypeselect.jsp?ent=01I150000017oVu&retURL=%2F0060S000002E9GH&save_new_url=%2Fa03%2Fe%3FCF00N1500000CxfPc%3DAgent%2BTest%2B-%2B2017-03-21%26CF00N1500000CxfPc_lkid%3D0060S000002E9GH%26retURL%3D%252F0060S000002E9G

My custom button:

/setup/ui/recordtypeselect.jsp?ent=01I150000017oVu
&save_new_url==%2F{Quotes_RFR.Id}
&retURL=%2F{!Opportunity.Id}
&00N1500000HvjMd={!Opportunity.OwnerFullName}
&00N1500000Cxfq6={!Opportunity.Sales_Support_Contact__c}
&00N1500000Cxfsc={!Opportunity.Date_Received__c}
&00N1500000Cxfrg={!Opportunity.Date_Due__c}
&00N1500000CxftK="Being Worked"

After I select the record type I get the error:

Invalid Page Redirection The page you attempted to access has been blocked due to a redirection to an outside website or an improperly coded link or button. Please contact your salesforce.com Administrator for assistance. For more information, see Insufficient Privileges Errors.

1

I think there is == in save_new_url==%2F{Quotes_RFR.Id} make it single =.

And use URLENCODE function for substitution.

/setup/ui/recordtypeselect.jsp?ent=01I150000017oVu
&save_new_url=/{!URLENCODE (Quotes_RFR.Id)}
&retURL=/{!URLENCODE (Opportunity.Id)}
&00N1500000HvjMd={!URLENCODE(Opportunity.OwnerFullName)}
  • I changed it as indicated, but I am getting the error message:Error: Field Quotes_RFR.Id does not exist. Check spelling. – Michelle Mar 28 '17 at 15:43
  • @Michelle, Probably because you are not using proper field name. – Raul Mar 28 '17 at 15:46
  • It is my custom object that I am trying to create off of the opportunity – Michelle Mar 28 '17 at 15:49
1

In past, had faced similar issues due to encoding of parameters, without which URL becomes invalid as error message suggests.

Should use URLENCODE for all the parameters.

Like:

{!URLENCODE(Opportunity.OwnerFullName)}
0

After much research and trial and error this worked /setup/ui/recordtypeselect.jsp?ent=01I150000017oVu &save_new_url=a03/e &retURL={!Opportunity.Id} &CF00N1500000HvjMd={!Opportunity.OwnerFullName} &CF00N1500000HvjMd_lkid={!User.Full_Name__c} &CF00N1500000CxfPc={!Opportunity.Name} &CF00N1500000Cxfq6={!Opportunity.Sales_Support_Contact__c} &00N1500000Cxfsc={!Opportunity.Date_Received__c} &00N1500000Cxfrg={!Opportunity.Date_Due__c}

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.