.SiteGroups()
and .SiteUsers()
queriable collections correspondingly..AddUser
method the argument should be full and valid login name including security provider membership prefix. For instance, while you can ensure Jane using [email protected]
the same as an .AddUser
method will fail as Jane's login is actually different i:0#.f|membership|[email protected]
..AddUserByID
helper is at the disposal.