1

I'm having a bit of an issue with my visualforce page. Our users in the US have no problem viewing the page but when our users in the Philippines try to access the page it throws the error following error :

"Insert failed. First exception on row 0; first error: INVALID_ID_FIELD, You must specify a FirstPublishLocation where you have publish permission.: [FirstPublishLocationId]. Error is in expression '{!sendData}' in component in page sfax"

Below is the visualforce markup:

<apex:page controller="sFax" showheader="false">
<apex:pageMessages />
<style>
input.btn{
margin:15px;
}
form{
text-align:center;
width:100%;
postion:fixed;
float:left;
bottom:0;
/*height:150px;*/
border-top: 5px solid #000033;
}
</style>

<apex:iframe src="{!page}" scrolling="true" id="theIframe"/>
<apex:form >
<apex:inputField value="{!fax.fax}" rendered="{!IF((RecipientRender ==     "False"),"True","False")}"/>
<apex:inputField value="{!recipient.Primary_Physician__c}" rendered="    {!RecipientRender}" />
<apex:commandButton action="{!sendData}" value="{!IF((RecipientRender ==   "False"),"Send","Select Recipient")}"/>
<apex:commandButton action="{!getDownload}" value="Download as Doc"/>

</apex:form>
</apex:page>

Below is also the code from the method in the error message(from the controller):

public pageReference sendData()
{
 if (params.get('sfaxrecipient') == null)
{
 pageReference pageref2 = ApexPages.currentPage();
 pageref2.getParameters().put('sfaxrecipient',newacct.Primary_Physician__c);
 pageref2.getParameters().put('pid',newacct.Primary_Physician__c);
 pageref2.setRedirect(true);
 return pageref2;

}

Thanks.

0

I think it has to do with Content permissions. Is your code creating Content? Do the users have access to the library where the content is getting created?

1
  • Hi Dan, I am actually looking at the library permission settings for the users. Even though I didn't setup the user I know the user was setup with the same profile as some of our users here in the States. Will take a look at that I a giffy. Thanks. May 29 '13 at 22:55
0

Are you manipulating content? This error seems to be related to users not having permissions to a library.

2
  • Hey Pepe. yup about to check the permissions for the user. Thanks May 29 '13 at 22:56
  • Thanks Dan and Pepe, you're both right. It was a sort of a permission issue.The problem was that those users were not included in the public group that had access to the Contents(if that made sense). I added them to the right public group and voila, they were able to view the pages. May 30 '13 at 4:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.