Hello
I am trying to configure my SharePoint 2013 site through PowerShell, but I am having a hard time connecting to it. I've opened SharePoint Online Management Shell, made a new PSSession with this command:
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri URL HERE -Credential $UserCredential -Authentication Basic -AllowRedirection
After this, I imported the session that I created.
This is where I get stuck. I want to add myself as a SPShellAdmin (I don't know if I am by default, as an Office 365 administrator) but it returns the error "Add-SPShellAdmin : The term 'Add-SPShellAdmin' is not recognized as the name of a cmdlet, funtion, script file or operable program etc.."
My final goal is to run this command succesfully:
Export-SPWeb -Identity <SiteURL> -Path <Path and File Name> [-ItemUrl <URL of Site, List, or Library>] [-IncludeUserSecurity] [-IncludeVersions] [-NoFileCompression] [-GradualDelete] [-Verbose]
What would be the correct way to run this, from scratch?
Thanks in advance
Best regards,
Jannik