You need to sign in to do that
Don't have an account?
Nitesh Sisodia
Change parent records of all "Salesforce Files Records" from standard contract object to some custom contract__c object
As we already know that Sandard Contract Object have a Files Related List on detail page layout. One of my colleague wants those Files must move to some Custom Contract__c object's "Files Related List"
I have already tried adding a custom Lookup Relationship field (parentId__c) in "Salesforce Content Version Object" to Contract__c custom object, and later assign contract__c ID in parentId__c field. But the records are coming in "Content Version" related list not in Files Related list, which is not according to requirement.
A little help in this would be appreciated !!
I have already tried adding a custom Lookup Relationship field (parentId__c) in "Salesforce Content Version Object" to Contract__c custom object, and later assign contract__c ID in parentId__c field. But the records are coming in "Content Version" related list not in Files Related list, which is not according to requirement.
A little help in this would be appreciated !!
you can add file related list on your custom object
in the setup ---quick find box search --> object --> select your custom object
in object detail page go to Page Layouts and click on edit link now select Related list in panal and add File object in your custom object related list pagelayout
Thanks
mark it best answer if it helps you :)
@Piyush, Thanks for reply,
Just to add more clarification to my question,
All I want to move is, all the salesforce Files records which belogs to standard Contract Object (Contract) to A Custom Contract Object (Contract__c). (Obviously, as a child records)
Lets suppose, I have multiple standard contracts which have multiple files attached as Salesforce Files, [Note : Its not attachment]
Contract Records :
Contract__c Records :
After map those same files to Contract__c, the final result would be something like, below table :
Because, Records in Contract and Cotract__c have same name, I was planning to write some apex around this which can copy all the Files from Contract to Contract__c, but doesn't find anything good around this.
As we know, that files and contentversion represents the same records, So I have already tried adding a custom Lookup Relationship field (parentId__c) in "Salesforce Content Version Object" which points to Contract__c custom object, and later assign contract__c ID in parentId__c field. But the records are coming in "Content Version" related list not in Files Related list, which is not according to requirement.
Thanks,