0 votes

can someone explain me how can I use this virual property adm-CustomAttributeTextMultiValue1?
Thanks for your help

by (700 points)

1 Answer

0 votes
by (215k points)

Hello,

The property can be used to store multiple string (text) values, for which you can't find an appropriate Active Directory property.

The same as with any other Adaxes virtual property, CustomAttributeTextMultiValue1 is stored not in Active Directory, but on Adaxes backend, and you can use it as any other property of AD objects.

0

Hello,

I'm refrencing %adm-CustomAttributeTextMultiValue1% in a email notification however only the first value is returned?

This behaviour is by design.

Do I still need to use the script?

Yes, currently all values can be returned only using a script. However, we have this feature on our TODO list.

0

Hi all, there is any way to put all values in a mail with other text? For example: Good morning.... below the list: %adm-CustomAttributeTextMultiValue1%_1 %adm-CustomAttributeTextMultiValue1%_2

thanks

I hope my request is clear Thanks in advance, Simone

0

Hello Simone,

Unfortunately, there is no such possibility using value references. It can only be done by retrieving all the property values in a script and sending the email in the very same script. To obtain all values of a multivalued property, use method GetEx.

0

Thanks, can I have an example? Sorry but I'm not confident with this type of scripts

0

Hello Simone,

Sure, here is an example of the script. In the script:

  • $multiValuedPropertyName - Specifies the LDAP name of the multivalued property.
  • $separator - Specifies the separator for values of the property in the email notification.
  • $to - Specifies the address of the email notification recipient.
  • $subject - Specifies the subject of the email notification.
  • $messageTemplate - Specifies the email notification template. In the template, the {0} and {1} placeholders will be replaced with the property LDAP name and its values accordingly.
$multiValuedPropertyName = "adm-CustomAttributeTextMultiValue1" # TODO: modify me
$separator = ";" # TODO: modify me

# Mail settings
$to = "recipient@domain.com" # TODO: modify
$subject = "My Subject" # TODO: modify
$messageTemplate = @"
Hello,

Here are values of property {0} for user %fullname%:
{1}
"@ # TODO: modify

# Get property values
try
{
    $valuesArray = $Context.TargetObject.GetEx($multiValuedPropertyName)
}
catch
{
    $Context.LogMessage("Property $multiValuedPropertyName is empty.", "Warning")
    return
}

# Send mail
$values = [System.String]::Join($separator, $valuesArray)
$message = [System.String]::Format($messageTemplate, @($multiValuedPropertyName, $values))
$Context.SendMail($to, $subject, $message, $NULL)

Related questions

0 votes
1 answer

Our security department has identify a vulnerability on our self service portal that allows cross-site request forgery and clickjacking due to allowing iframes openly. They ... site in an iframe. https://www.adaxes.com/questions/889/adselfservice-security

asked Jun 30, 2020 by mark.it.admin (2.0k points)
0 votes
0 answers

By default, SSL is not configured for the Adaxes Web Interface and network transmissions are not encrypted. However, you can configure SSL on the Adaxes Web ... work in both cases: with Windows-integrated authentication and with forms-based authentication.

asked Oct 14, 2010 by Adaxes (380 points)
0 votes
0 answers

We are replacing our Namescape rDirectory product with Adaxes because of the very flexible automation components. I've been able to replicate some of the pages previously ... vast majority of our users, that would function as the default company directory.

asked 2 days ago by MRBruce (110 points)
0 votes
1 answer
0 votes
1 answer

We have multiple types of user accounts, example: Employee, Contractor, Intern. Based on this, we have different requirements for AD properties and property patterns. I would ... relevant properties when creating a type of user account, how can I achieve this?

asked Apr 8 by jcrook (60 points)
2,779 questions
2,511 answers
6,574 comments
25,626 users