Hi @Raja ,
I tested with the code snippet below to delete a file item in host web from Provider Hosted Add-in:
private void DeleteItem(int id)
{
try
{
var spContext = SharePointContextProvider.Current.GetSharePointContext(Context);
using (var context = spContext.CreateUserClientContextForSPHost())
{
Web web = context.Web;
List oList = web.Lists.GetByTitle("Doc3");
Microsoft.SharePoint.Client.ListItem oListItem = oList.GetItemById(id);
oListItem.DeleteObject();
context.ExecuteQuery();
}
}
catch (Exception ex)
{
throw ex;
}
}
It's triggering ItemDeleting event by debugging with break point:
I suggest you can try to debug Event Receiver with break point to see if it triggered event or not.
And here is a reference to access host web data in Provider hosted add in for your reference:
Accessing SharePoint Data from Provider-Hosted Apps: Use the Right Context
Thanks
Best Regards
If an Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.