Sideloading of apps is not enabled on this site – Office 365

When creating an App for SharePoint 2013, there is a hidden ‘developer feature’ that must be turned on – otherwise, you will get this error (Visual Studio)

image

To turn this on for “on-prem” SharePoint 2013 – you simply need to do this :

Enable-SPFeature e374875e-06b6-11e0-b0fa-57f5dfd72085 –url http://sp.contoso.com

(Thanks to Joe Rodgers for that tip)

But, of course, it’s trickier – as you can’t run a ‘local’ PowerShell command.

I found another blog post that explained how to activate a feature on SharePoint+Office365 – thanks Kanwartej Basrai.

Here’s the full script you need to run – to activate the “developer feature” for Office365 – and thus allow you to run custom coded App’s – phew !

============================================

Import-Module Microsoft.Online.SharePoint.Powershell

$developerFeature = “e374875e-06b6-11e0-b0fa-57f5dfd72085”

$siteUrl = https://MYTENANT.sharepoint.com
$userName = “admin@MYTENANT.onmicrosoft.com”
$password = ConvertTo-SecureString -String ‘MyPass@word1’ -AsPlainText -Force

[Microsoft.SharePoint.Client.ClientContext]$clientContext = New-Object Microsoft.SharePoint.Client.ClientContext($siteurl)  

$clientContext.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($userName, $password)
$site = $clientContext.Site;    

$featureguid = new-object System.Guid $developerFeature    
$site.Features.Add($featureguid, $true, [Microsoft.SharePoint.Client.FeatureDefinitionScope]::None);

$clientContext.ExecuteQuery();     

 

=============================================

** Before you run the above script, you might have to install the ‘plug-in’ for remote connectivity – see here for info :

http://office.microsoft.com/en-au/sharepoint-help/set-up-the-sharepoint-online-management-shell-environment-HA102919087.aspx

And also – if you haven’t yet run any PowerShell commands from your local PC, make sure to “Run-As-Admin” when you open PowerShell – and execute THIS command :

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned​

Hope that helps – leave a comment if it did !

 

🙂

Advertisements

3 thoughts on “Sideloading of apps is not enabled on this site – Office 365

  1. Pingback: SharePoint Online: ¿Se pueden activar features mediante PowerShell? - Blog de Juan Carlos González en Geeks.MS

  2. Pingback: ¿Se pueden activar features mediante PowerShell? - Blog de la Comunidad de Office 365 - Office 365 - Español - Microsoft Office 365 Community

  3. By Derek Jansen of Derek – Jay Entertainment – specialising in and in
    South Africa. If you have an overloaded broadband connection or a dial up connection and your free movies
    downloads are coming in at a snails pace, then do what I do on
    occasion. In some countries, taxes are levied during the
    purchase of these points.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s