---
title: "GetValidADUserName (Opus Funktion)"
---
[TOC]

#### Beschreibung

Generates a unique Active Directory user name from the first and last name of the given address. Appends a numeric suffix if the plain name is already taken.

#### Argumente

<table style="table-layout: fixed; width: 100%;"><colgroup><col style="width: 14.4%"><col style="width: 9.8%"><col style="width: 75.8%"></colgroup><tr><th><p>Name</p></th><th><p>Typ</p></th><th><p>Beschreibung</p></th></tr><tr><td><p> AddressID</p></td><td><p><a href="/smt-school-professional/technische-dokumentation/opus-dokumentation/standard-datentypen/integer/">integer</a></p></td><td><p>ID of the address record to generate the user name for</p></td></tr><tr><td><p>MaxLength</p></td><td><p><a href="/smt-school-professional/technische-dokumentation/opus-dokumentation/standard-datentypen/integer/">integer</a></p></td><td><p>maximum number of characters the generated user name may have</p></td></tr></table>

#### Rückgabewert [<u>string</u>](../../standard-datentypen/string.md)

a unique Active Directory user name derived from the person's name

#### Beispiel

`xxx`

#### Siehe auch

---
