Hi all,
I am writing a quick application to make my LDAP administration a bit easier (using Novell.Directory.Ldap namespace). I load the attributes of a user into a list view with two columns (attribute and value). An example of the contents is below;
[attribute] [value]
cn test account2
sn account
objectClass top
objectClass shadowAccount
objectClass person
objectClass organizationalPerson
objectClass inetOrgPerson
objectClass inetLocalMailRecipient
objectClass posixAccount
shadowLastChange 11458
shadowMax 99999
shadowWarning 7
loginShell /bin/false
uid test.account2
userPassword password
uidNumber 11111
gidNumber 11111
homeDirectory /home/users/test.account2
mail
[email protected]
mailHost mail.test.com
Now i need to get that info into an Array which is easy enough however when i write this array back to LDAP it ends up removing all but one of the objectClass attributes. I think i may need to create a multidimension array to store the objectClass attributes but i'm not sure..
ArrayList modlist = new ArrayList();
try
{
int count = objectView.Items.Count;
for(int x=0; x