You need to sign in to do that
Don't have an account?
Stéphane C.
How to update Child Records based on Parent Record
Hi,
I am writing an inline visualforce page to update parent records and thier child records.
The visualforce page have a controller :
I can't see the way.
Any idea? Thank you!
I am writing an inline visualforce page to update parent records and thier child records.
The visualforce page have a controller :
public class inlineDetail { public List<contact> contactList=new List<contact>(); public List<course__c> courseList=new List<course__c>(); public List<contact> getContacts() { contactList=[select name,accountId,phone,AssistantPhone,email, (select name, classroom__c, comments__c from Courses__r) from Contact]; return contactList; } public void saveChanges() { update contactList; if(!courseList.isEmpty()) update courseList; } }I want to update the parent records and the "comments" child records when they change.
I can't see the way.
Any idea? Thank you!
Any comments will be appreciated.
All Answers
Any recommendations? Thank you.
Any comments will be appreciated.