+ Start a Discussion

Update Description field in ContentDocument Object

Im Working on one scenario update description value in ContentDocument Object.
This my piece of code.
//Update Description value in ContentDocument object
        List<ContentDocument> lstcd = new List<ContentDocument>();
        for(ContentDocumentLink cdl: [SELECT Id, ContentDocument.Description, ContentDocumentId, ContentDocument.LatestPublishedVersionId FROM ContentDocumentLink WHERE LinkedEntityId = '500N0000002hZC9'])
            ContentDocument cd = new ContentDocument();
            cd.id = cdl.ContentDocumentId;
            cd.Description = 'Testing';

        update lstcd;
But im getting this Error: Compile Error: Field is not writeable: ContentDocument.Description

Please advise on this
Francesco Carmagnola 10Francesco Carmagnola 10
It seems that the field doesn't have the write property:

User-added image