Office.EmailUser interface

Представляет учетную запись электронной почты на сервере Exchange Server.

EmailUser объекты в основном получаются в сущностях MeetingSuggestion и TaskSuggestion , извлеченных из элемента Outlook. Дополнительные сведения об этом сценарии см. в статье Извлечение строк сущностей из элемента Outlook.

Комментарии

Минимальный уровень разрешений: чтение элемента

Применимый режим Outlook: чтение

Примеры

// The following example is an excerpt from a larger sample.
// For the full sample, visit https://learn.microsoft.com/office/dev/add-ins/outlook/extract-entity-strings-from-an-item.

// Gets instances of the task suggestion entity on the item.
function myGetTaskSuggestions()
{
    let htmlText = "";

    // Gets an array of TaskSuggestion objects, each array element 
    // containing an instance of a task suggestion entity from 
    // the current item.
    const tasksArray = _MyEntities.taskSuggestions;

    // Iterates through each instance of a task suggestion.
    for (let i = 0; i < tasksArray.length; i++)
    {
        // Gets the string that was identified as a task suggestion.
        htmlText += "TaskString : <span>" + 
        tasksArray[i].taskString + "</span><br/>";

        // Gets an array of assignees for that instance of a task 
        // suggestion. Each assignee is represented by an 
        // EmailUser object.
        let assigneesArray = tasksArray[i].assignees;
        for (let j = 0; j < assigneesArray.length; j++)
        {
            htmlText += "Assignee : ( ";
            // Gets the displayName property of the assignee.
            htmlText += "displayName = <span>" + assigneesArray[j].displayName + 
            "</span> , ";

            // Gets the emailAddress property of each assignee.
            // This is the SMTP address of the assignee.
            htmlText += "emailAddress = <span>" + assigneesArray[j].emailAddress + 
                "</span>";

            htmlText += " )<br/>";
        }

        htmlText += "<hr/>";
    }

    document.getElementById("entities_box").innerHTML = htmlText;
}

Свойства

displayName

Получает отображаемое имя, связанное с адресом электронной почты.

emailAddress

Получает адрес электронной почты SMTP.

Сведения о свойстве

displayName

Получает отображаемое имя, связанное с адресом электронной почты.

displayName: string;

Значение свойства

string

emailAddress

Получает адрес электронной почты SMTP.

emailAddress: string;

Значение свойства

string