private void CreateNewPortalOrgUnit(DirectoryEntry entry, string parentPath, Guid guid, SyncTree syncTree)
{
try
{
AdLog.LogADObject(string.Format("New portal orgunit - creating under {0}", parentPath), entry.Path);
OrganizationalUnit newOu = new OrganizationalUnit(Node.LoadNode(parentPath));
UpdatePortalOrgUnitProperties(entry, newOu, syncTree);
Common.UpdateLastSync(newOu, guid);
//newOu.Save(); - update lastsync already saves node
if (_portalContainers != null)
{
if (!_portalContainers.ContainsKey(guid.ToString()))
_portalContainers.Add(guid.ToString(), newOu.Id);
}
}
catch (Exception ex)
{
AdLog.LogException(ex);
}
}
private void CreateNewPortalUser(DirectoryEntry entry, string parentPath, Guid guid, SyncTree syncTree)