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
JuulJuul 

URL hacking

Hi,

 

I need some help with my URL hacking. I want to create a new button on the accountpage to create a child account.

So I only need to pre-populate the parent name and the recordtype. When clicking on the new button it opens a new account, with the correct recordtype but without the name of the account in the parent field.

 

I'm not sure if I have to use the fieldnames for Parent and ParentID, perhaps there are some other ID's for these fields.....

 

/001/e?Parent={!Account.Name}&ParentId={!Account.Id}&RecordType=01220000000Q3wo&retURL=/{!Account.Id} 

 

Thanks

Best Answer chosen by Admin (Salesforce Developers) 
JuulJuul

Never mind. I've found the solution:

 

With help of this addon in firefox: https://success.salesforce.com/questionDetail?qId=a1X30000000HYt4EAG

 

The ID for Parent = acc3

 

/001/e?acc3={!Account.Name}&ParentId={!Account.Id}&RecordType=...................&retURL=/{!Account.Id}

All Answers

JuulJuul

Thanks. This page is already in my favourites. But there is no reference to Parentname and parentid.

 

So any other solution?

 

 

JuulJuul

I've used this one as well, But the example is written about a custom object an I want to create a url hack for the standard object Account.

 

When I click on the 'new child' button it needs to prepopulate the parent name and the recordtype id. But for some reason I can't find the ID for the parentname so I've tried to use the fieldname instead, but this isn't working.

JuulJuul

Never mind. I've found the solution:

 

With help of this addon in firefox: https://success.salesforce.com/questionDetail?qId=a1X30000000HYt4EAG

 

The ID for Parent = acc3

 

/001/e?acc3={!Account.Name}&ParentId={!Account.Id}&RecordType=...................&retURL=/{!Account.Id}

This was selected as the best answer