• Daniel Roberts 23
  • NEWBIE
  • 10 Points
  • Member since 2018

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 2
    Replies
I'm doing some trailheads on visual force pages, and in this particular module, you learn that you can use the following code snippet to create accounts. 
 
<apex:outputLink value="{!URLFOR($Action.Account.New)}">
    Create New Account
               
</apex:outputLink>

However, I can't get it to do the same thing for contacts when I replace Account with contact. And I get an error that says "Field$Action.Contact.New does not exist. Check Spelling" 

The code that I have is this: 
 
<apex:pageBlock>
        <apex:pageBlockSection>
            <apex:outputLink value="{!URLFOR($Action.Contact.New)}">
    Create New Contact
</apex:outputLink>
            </apex:pageBlockSection>
         </apex:pageBlock>

The documentation says that the "new method" is compatible with Contacts, I just don't know how to get it to work. 

Thanks, 
I'm doing some trailheads on visual force pages, and in this particular module, you learn that you can use the following code snippet to create accounts. 
 
<apex:outputLink value="{!URLFOR($Action.Account.New)}">
    Create New Account
               
</apex:outputLink>

However, I can't get it to do the same thing for contacts when I replace Account with contact. And I get an error that says "Field$Action.Contact.New does not exist. Check Spelling" 

The code that I have is this: 
 
<apex:pageBlock>
        <apex:pageBlockSection>
            <apex:outputLink value="{!URLFOR($Action.Contact.New)}">
    Create New Contact
</apex:outputLink>
            </apex:pageBlockSection>
         </apex:pageBlock>

The documentation says that the "new method" is compatible with Contacts, I just don't know how to get it to work. 

Thanks,