• System Admin 1038
  • NEWBIE
  • 0 Points
  • Member since 2019

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies
I would like to set up a process that all files are editable by the whole company. I can set each file manually to have whole company collaboration but this is a pain and forces users to memorize steps. I tried to have a trigger on insert that would add a ContentDocumentLink with a link to the org Id and sharing set to C. As far as I can tell, the documentation out there says that what I'm doing is correct.

Apex is below.  It hits the try/ catch below and fails with "12:24:06:252 USER_DEBUG [16]|DEBUG|Exception occurred on insert: Insert failed. First exception on row 0; first error: INSUFFICIENT_ACCESS_OR_READONLY, Invalid sharing type C: [ShareType]"
Hi,

I am trying to use JQuery date picker in visualforce page. The JQuery date picker is not overwriting the standard salesforce style for apex:input field. Code below:

<apex:page id="thePage" standardController="Interaction__c">
<head>
  <link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" target="_blank" rel="nofollow"/>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css</a>" rel="stylesheet" type="text/css"/>
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js" target="_blank" rel="nofollow">
  <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js</a>"></script>
  <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js" target="_blank" rel="nofollow">
  <script src="<a href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js</a>"></script>  
  
   <script>
    jQuery(function(){
            var $j = jQuery.noConflict();
            $j("input[id$=datepicker]").datepicker({
               changeYear: true,
               changeMonth: true,
               dateFormat: "mm/dd/yy"
            });
          });
</script>
</head> 
  <apex:form >
  <apex:pageBlock >

  <apex:pageblockSection >
  <apex:inputfield value="{!Interaction__c.Call_Date__c}" id="datepicker"/>
  <apex:pageBlockSectionItem />
  </apex:pageblockSection>
  </apex:pageBlock>

  
  </apex:form>

</apex:page>

Let me know if some thing else needs to be done.