function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
DarbDarb 

Create a new Case from an opportunity - using a button

I want to create a new case from an opportunity.  I have built the connection between the two using a lookup relationship.  Now I have a button on the case related list to allow users to create a new case directly from the opportunity.  I want to make it as easy as possible by pulling in related information from the opportunity so the user does not have to reenter it. The challenge I now have is that I have multiple accounts with the same name and the user must then select the correct account.  Is there a way to pull the account from the opportunity without having the user look the correct one up from a list?  The button URL is listed below. 

 

 

 

/500/e?&cas4={!Opportunity.Account}&cas8=Medium&CF00N50000002Seac={!Opportunity.Name}&cas11="Opportunity"&RecordType=01250000000DvtV

Best Answer chosen by Admin (Salesforce Developers) 
Abhay AroraAbhay Arora

cas4_lkid={!Account.id}&cas4={!Account.Name}

 

this will solve your issue as there will be a problem when you pass account name and there are more than one account with same name

All Answers

TrimbleAgTrimbleAg

Try this

 

&cas4={!Account.Name}

I have the same button as you are creating and lots of accounts with the same name, I havent heard of the issue you describe, so maybe this method will work for you?

 

PB

Abhay AroraAbhay Arora

cas4_lkid={!Account.id}&cas4={!Account.Name}

 

this will solve your issue as there will be a problem when you pass account name and there are more than one account with same name

This was selected as the best answer
DarbDarb

This worked, thank you for your help.

Rachael TorrenceRachael Torrence
 I have a similiar question.
/500/e?cas4_lkid={!Account.Id}&cas4={!Account.Name}&&cas8=Medium&CF00NF000000CjRiO={!Opportunity.Name}

Not having any issues with either Account or Opportunity coming over on this record type. 
First Record type check

I have copied your url with my own info and I am having difficulty with the Opportunity coming over without having to search for the opportunity name on this record type. Could you help?


/500/e?cas4_lkid={!Account.Id}&cas4={!Account.Name}&cas8=Medium&CF00NF000000CjRiO={!Opportunity.Name}&Cas11="opportunity"&RecordType=012F00000013OJN


Test Case button