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
Shree KShree K 

Need help on URL hacking to pre populate Record Type Name and Parent Id

Hi All,
I have a custom object Interests (with only 2 Record types Primary and Secondary) which is a child to Account (lookup relationship) and Account has a Related List to create child records.

1) Standard Process : The standard "New" button lets the users to redirect and select the record type of their choice to create Child records(Interests).
what i am looking for is a customized solution (Probably URL hacking) with a custom list button which should redirect the users straight away to the edit mode and Prepopulate the Account (Parent ID) and the Primary (record type) on the  child record that is going to be created,in other words when the users are redirected from the Parent Record(Account) the child record that is going to be created should have the Parent Id in the lookup field and be with its record type as Primary.
I am thinking of 2 ideas:
1) Having a custom button, upon click the users would be on edit mode by auto populating Record type (in the standad field) and the parent ID.
2) Having a custom button which lets the users to a custom VF Page where there would be only a button, upon click of the button the record type will be populated as Primary and auto populating the Parent id when creating the child record.

Now all i need is a URL to make the things work, Please let me know if anyone has a better idea or with the possible apex work around for the URl part.

Raj VakatiRaj Vakati
REfer this link
Hi Shree,

Now URL hack is supported in Lightning Experience. Check below post for detail and code sample:
These were extremely helpful: