You need to sign in to do that
Don't have an account?
Thomasm
Button to create new record and recordtype
I currently have a page with a command button that creates a new record. I would like to predefine the recordtype to the user goes directly to the page
Here is what i currently have
<apex:commandButton value="Salary Time Off Request" action="{!URLFOR($Action.Forms__c.New)}"/>
Here is what i currently have
<apex:commandButton value="Salary Time Off Request" action="{!URLFOR($Action.Forms__c.New)}"/>
<apex:commandButton value="Rate Change" action="{!URLFOR('/a10/e?RecordType=012a0000001NWwY&ent=01Ia0000002Kw9e')}"/>
All Answers
You need to pass string instead standard action in target attribute of URLFOR().
Here instead $Action.Forms__c.New provide '/FIRST_3_SYMBOLS_OF_FORMS_RECORD_ID/e?&RecordType=RECORD_TYPE_ID'
As a common practice, if your question is answered, please choose 1 best answer.
But you can give every answer a thumb up if that answer is helpful to you.
Thanks,
Alex
<apex:commandButton value="Rate Change" action="{!URLFOR('/a10/e?RecordType=012a0000001NWwY&ent=01Ia0000002Kw9e')}"/>