I tried binding ADAM with
DirectoryContext adamContext = new DirectoryContext();
To use
ActiveDirectorySchema schema = ActiveDirectorySchema.GetSchema(adamContext);
In this link: http://msdn.microsoft.com/en-us/library/bb267453.aspx
Unfortunately DirectoryContext needs 3 values which are the server name, userID and pw.
I only have a Card that I use to authenticate into the network. Is there any alternative or workaround to using DirectoryContext to bind with ADAM?
I wouldn’t expect you to need to provide a username and password explicitly, as long as the ADAM server is in the same domain where you’ve logged on.
This code works for me:
Have you confirmed that the user account you are running under as been granted permissions on the ADAM server? If you’re not sure, let me know and I can find a link to help you.