Posts

Showing posts with the label sharepoint

The 'username' argument is invalid. while connecting to SharePoint Online Manager

The 'username' argument is invalid. while connecting to SharePoint Online Manager I am connecting to SharePoint Online Manager like this below:- protected SharePointOnlineCredentials GetCredentials() { return new SharePointOnlineCredentials(this.UserName, this.GetSecurePassword(this.Password)); } I get an error saying - The 'username' argument is invalid. Below is the SharePoint Online Credentials Class:- #region Assembly Microsoft.SharePoint.Client.Runtime, Version=16.1.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c // C:SourceCodePDS PortalJLL.PDSpackagesMicrosoft.SharePointOnline.CSOM.16.1.4727.1200libnet45Microsoft.SharePoint.Client.Runtime.dll #endregion using System; using System.Net; using System.Security; namespace Microsoft.SharePoint.Client { public sealed class SharePointOnlineCredentials : ICredentials { public SharePointOnlineCredentials(string username, SecureString password); p...