2015-11-03 93 views
0

某些字段的“其他”一选项为多个值: AD fields screenshot增值“其他”属性在Active Directory中的AD

我试着用下面的代码添加新值这个领域:

if (Domaincontact.Telephones.Faxes != null) 
    { 
    foreach (var fax in Domaincontact.Telephones.Faxes) 
     { 
     if(activeDirectoryContact.Properties[FAX].Contains(fax)) continue; 
      activeDirectoryContact.Properties[FAX].Add(fax); 
     } 
    } 
activeDirectoryContact.CommitChanges(); 

但最后的代码行后有一个例外:

ExtendedErrorMessage = "00002081: AtrErr: DSID-031517FA, #2:\n\t0: 00002081: DSID-031517FA, problem 1005 (CONSTRAINT_ATT_TYPE), data 0, Att 17 (facsimileTelephoneNumber)\n\t1: 00002081: DSID-031517FA, problem 1005 (CONSTRAINT_ATT_TYPE), data 0, Att 17 (facsimileTelephoneNumber)\n" 

哪些错误与AD? ; D有人能告诉我我缺少什么吗?

+0

FAX –

回答

0

好的。我自己想通了。这里的link为AD字段的说明。我的方案将是:

otherFacsimileTelephoneNumber

及其他:在这个例子中`FAX = “facsimileTelephoneNumber”`

otherHomePhone otherIpPhone otherLoginWorkstations otherMailbox otherMobile otherPager otherTelephone

相关问题