I use a sandbox solution in office 365 and I want to send an email to a external user. So I created a list workflow to send email and works fine, but if I access the site like an anonymous user, the workflow don´t complete.
Is it possible to run a workflow with anonymous user in a office 365 sandbox solution?
I think it should be possible .. You may need to provide access to anonymous user on your list
1. Enable Anonymous access at the Web Application level
Go to SharePoint Central Administration => Application Management, select the Web Application => Authentication Providers, click on the zone, and select Enable anonymous access
2. Now, navigate to the corresponding web site, Site Action => Site Permissions => Anonymous Access.
Configure what anonymous users can access at the site level
3. Break the permission inheritance on the specific list
List Settings => Permissions for this list => Stop Inheriting Permissions, click OK => Anonymous Access
Select Add Items.
4:- Run this code in your console app or equivalent code in powershell
SPWebApplication webApp = SPWebApplication.Lookup(new Uri(webAppUrl)); webApp.ClientCallableSettings.AnonymousRestrictedTypes.Remove(typeof(Microsoft.SharePoint.SPList), "GetItems"); webApp.ClientCallableSettings.AnonymousRestrictedTypes.Remove(typeof(Microsoft.SharePoint.SPList), "AddItem"); webApp.Update();
5:- do IISREST
Manoj Gangwar | Sharepoint MCPD | Sharepoint MCTS |
We can create an Event Receiver and start the workflow in it.
Here is a link for you to take a look at:Best Regards
TechNet Community Support