none
C# help with hiding terminated users RRS feed

  • Question

  • I am trying to put in code to hide terminated users from the GAL using our AD MA

    I have the following code:

    case "msExchHideFromAddressLists":
                    if (mventry["employeeStatus"].IsPresent && mventry["employeeStatus"].Value.ToLower() == "terminated" || mventry["cccEmployeeStatus"].IsPresent && mventry["cccEmployeeStatus"].Value.ToLower() == "terminated")
                    {
                        csentry["msExchHideFromAddressLists"].BooleanValue = true;
                    }
                    break;

    It keeps giving an error that the attribute is read only, or it does nothing at all..

    Any assistance would be appreciated thanks


    Russell Lema

    Tuesday, July 7, 2015 8:52 PM

Answers

  • I found the issue, I was not looking at employeeStatus in the attribute flow. I was banging my head for nothing. Thanks for the help.

    Russell Lema

    • Marked as answer by Russ Lema Thursday, July 9, 2015 4:04 PM
    Thursday, July 9, 2015 4:04 PM

All replies

  • Hello,

    that should work, done this a lot of times in my scenarios.

    Are you accidentially in the MapAttributesforImport Section ?

    Did you also select the attibutes employeeStatus and cccEmployeeStatus in the flow rule mapping of the ma ?

    /Peter


    Peter Stapf - ExpertCircle GmbH - My blog: JustIDM.wordpress.com

    • Proposed as answer by Nosh Mernacaj Wednesday, July 8, 2015 2:06 PM
    Wednesday, July 8, 2015 8:21 AM
  • I found the issue, I was not looking at employeeStatus in the attribute flow. I was banging my head for nothing. Thanks for the help.

    Russell Lema

    • Marked as answer by Russ Lema Thursday, July 9, 2015 4:04 PM
    Thursday, July 9, 2015 4:04 PM