You need to sign in to do that
Don't have an account?
Custom Button with Record Type
I have a customer button that creates a Opportunity record. However I need it to also prefill the Record Type.
/006/e?retURL=/{!MyGovWatch__c.Id}&
opp3={!MyGovWatch__c.Buyer_Contract_Name__c}&
opp4={!MyGovWatch__c.Friendly_Name__c}&
CF00NE0000000KKWk={!MyGovWatch__c.Name}&
00NE0000000KP9r={!MyGovWatch__c.Forward_Flow_Dollars__c}
I tried adding...
&RecordTypeID="the name"
...but it didn't work. How can I define the record type. Right now it is making the record type the default.
Easiest way to find the RecordType Id is to create a new Opportunity select your recordtype, and when it takes you to your pagelayout lookat your url. Copy your recordType Id and use it on your custom button. RecordTypeId has to be the salesforce Id of that record type, not the name of your record type.
I tried...
/006/e?retURL=/{!MyGovWatch__c.Id}&
opp3={!MyGovWatch__c.Buyer_Contract_Name__c}&
opp4={!MyGovWatch__c.Friendly_Name__c}&
CF00NE0000000KKWk={!MyGovWatch__c.Name}&
00NE0000000KP9r={!MyGovWatch__c.Forward_Flow_Dollars__c}
I tried adding...
&RecordTypeID="012E00000000H88"
...and it still defaulted to the default Record Type for Opportunities. Any other ideas?
no quotes
It is still defaulting to the default Record Type. What other ideas to you have?
The url should be RecordType not RecordTypeId, just noticed that. You may want to take a look at your 5th line on your example here as it seems you are missing letters CF from your input name field
This is a working example from my current companies org I've written.
/a07/e?
RecordType=012600000005E9y&
CF00N60000001otaY={!Project__c.Name}&
CF00N60000001otaY_lkid={!Project__c.Id}&
CF00N60000002NSg6={!Project__c.Project_Manager__c}&
CF00N60000002NSg6_lkid={!Project__c.Project_ManagerId__c}
Perfect! Thanks so much! RecordType=001C000000ofDyR did it.