Custom C# Component – Adding a Computer to a Group in Active Directory

Symantec Connect user Turl posted a forum question asking how to add a computer to an Active Directory group in a Workflow project, because in the Active Directory component library, there’s no boxed component to do this.

Hello

I am trying to add a computer to an AD-Group in my Worklfow.

How can that be done?

I know that there is a component to add user to a Group. But there is no component for computers.

Does anyone have an idea how this could be solved?

Thanks

Turl

After a bit of effort (and learning, as I am not presently a respectable coder), I was able to create a custom C# Code (Script) Component that accomplishes this task.

Continue reading

Integrating LDAP and Workflow for Common Account Actions

All day this past Friday I was trying to get either the Active Directory components or the LDAP generated components to return some usable information on whether an account was locked out.  The only results I was able to get back was what I can only guess is some sort of riddle.

System.__ComObject

So, turns out that the solution for converting that into usable data was going to require way more effort than I was willing to give it, so I figured I may as well use my time for something more useful, like starting to learn C#.

The result of 2 days’ worth of effort finally paid off, and I’m able to pull a readable, usable value for an account’s lockout status.  I’m also able to set a password and unlock that account pretty easily.  Here’s some info on how to do it.

Continue reading