• Vijayakumar S 6
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies
On a custom object, I've managed to auto populate the custom object's name field to a default value using below custom apex page code:
<apex:page standardController="CustomObject__c"
    action="{!URLFOR($Action.CustomObject__c.New, null, ['Name'='Default Value'], true)}"  
/>
Now in addition to the Name field I also want to auto populate a Master-Detail field on the Custom object but it's not working. My code:
<apex:page standardController="CustomObject__c"
    action="{!URLFOR($Action.CustomObject__c.New, null, ['Name'='Default Value', Master-Detail__c='Default Value'], true)}"  
/>

I have been struggling to find reference to the proper syntax. I also have been wondering how does one view all the apex codes created for a custom object, as a starting point to learn the apex coding language.