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
txmapptxmapp 

override button and update object

hi

i have 2 customs objects, job__c and applicant__c, in the applicant object is a lookup field to job object there is a relation one to many,

all of this is ok

but in the object job apear a list with all the applicants that has register on this job,here there is a button new, i want to override this button, when a click  show me a new window with the id of this job, and a lookup for search an applicant

and update the field job on applicant__c, and in the list that is show in the object job__c apear the applicant that i update

 

i need to create a visualforcepage

a class

 

i have problems to override the button, and to when i create new button, when i select  source of content in the piklist not apear my visualforcepages

 

 

can somebody helpme?

florianhoehnflorianhoehn

Hi,

 

If you want this beahviour only for the list views you will have to create a custome 'List View Button' for this object which directs to the VF page. For this the VF page must use the StandardController of your object. In your case 'Applicant__c'.

 

Add this button to the related list in the PageLayout of 'Job__c' and you are done (remove the standard 'New' button there).

 

I haven't tried it exactly but this should point you in the right direction. Hope it helps!

 

Florian