My Xpages application is showing a strange problem. I have an XPage with with a tab control (2 tabs) and each tab has a dynamicviewpanel and a delete button. Each tab shows a different view depending on a condition. The first tab works completely fine for both myself and the user but the second tab, the view shows the correct documents and the delete button works fine for me and a fellow developer but when the user clicks on the delete button in the second tab they receive the error.
<xp:button id="DeleteContract" value="Delete Contract ID">
<xp:eventHandler event="onclick" submit="true"
refreshMode="complete">
<xp:this.action>
<xp:actionGroup>
<xp:confirm
message="Are you sure?">
</xp:confirm>
<![CDATA[#{javascript:var viewPanel=getComponent
("dynamicViewPanel3");
var docIDArray=viewPanel.getSelectedIds();
for(i=0; i < docIDArray.length; i++){
var docId=docIDArray[i];
var doc=database.getDocumentByID(docId);
doc.remove(true);
}}]]>
</xp:actionGroup>
</xp:this.action>
</xp:eventHandler>
</xp:button>
The error being presented on the browser is "Exception occurred calling method NotesDocument.remove(boolean) null"
The logs do not tell me much either
All the permissions are the same for each tab etc so it shouldn't be a permissions issue. Why would this be occurring?
Discovered the logic in the solution was working after all. It was bad feedback that was making us think the specific user could delete in one tab but not the other. After discovering the user could not delete from any tab, we found that they were a member of another lotus notes group that we could assign deletion privileges to and then all was working for them. Stupid I know, but it was confusing feedback that made me assume the user could delete in one tab but not the other. Thanks to all who contributed