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
LA_193LA_193 

I need specific documents to be shown which are realted to that record only..... it's very urgent

New page
------------------
<apex:page standardController="External_Interface__c extensions="ExternalInterface"> <apex:pageBlockSection title="Commerical Notes" columns="1"> <apex:commandButton value="Add Comments" action="{!AddComNotes}"/><br></br> <apex:repeat value="{!schwrap3}" var="c3"> <br><apex:inputField value="{!c3.childschool3.Commerical_Notes__c}" style="width:440px; height;130px;"/></br> <a href="#" onclick="Popup=window.open('https://cs5.salesforce.com/sfc/#workspaceView?selectedWorkspaceId=058O00000004GeB','Popup','toolbar=...menubar=no,scrollbars=yes,resizable=yes,width=520,height=500,left=330,top=43'); return false;">Choose Files</a> </apex:repeat> </apex:pageBlockSection> </apex:page> View page --------------------
<apex:page standardController="External_Interface__c" extensions="ContentVersions" > <apex:pageBlockSection title="Commerical Notes" columns="1" > <apex:repeat value="{!schwrap3}" var="c3"> <br><apex:outputField value="{!c3.childschool3.Commerical_Notes__c}" style="width:440px; height;130px;"/></br> <apex:datatable value="{!ws36}" var="wsd36" id="theList36" > <apex:column value="{!wsd36.ContentWorkspaceId }" headerValue="File Name"/> <apex:column value="{!wsd36.ContentDocumentId }" headerValue="File Name"/> </apex:datatable> </apex:repeat> </apex:pageBlockSection> </apex:page>




public class ContentVersions { List<ContentWorkspaceDoc> ws36; public ExternalInterface () { ws36= getRecords36(); } public List<ContentWorkspaceDoc> getWs36() { if(ws36 == null) ws36 = getRecords36(); return ws36; } public List<ContentWorkspaceDoc> getRecords36() { return[SELECT ContentWorkspaceId,ContentDocumentId FROM ContentWorkspaceDoc WHERE ContentWorkspaceId ='058O00000004GeB']; } }

 

Hi,

Actually my requirement is, my customer will upload number of documents into Single field only. So here I provided "Content" link to that field(only label not feild) in VF. Afte saving the record it is showing all uploaded documents which is not my requirment. I need specific documents to be shown which are releated to that record only.
Here am pasting my sample code. Please check the same and suggest............!

 

Thanks