Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

176
Visualizações
Outlook addin unable to fetch attachments

I am working on an outlook addin which needs to get the attachments for the mail. I am using office.js and the following code to fetch the mail item.

        Office.onReady( () => {        
        currentMailItem = Office.context.mailbox.item;
        const subject = currentMailItem.subject; // works fine;
        const attachments = currentMailItem.attachments; 
        //returns empty array for gmail configured in outlook
        //----- more code  -------
        }

Everything works as expected for outlook mails. I am able to access the properties such as subject, cc , bcc etc for outlook mails. But when I configured gmail inside outlook in mac , it fails to fetch the gmail attachments. Rest of the details ( subject, cc etc ) are available for use.

Is there any limitation on attachments in gmail ? or am I missing some additional steps to access gmail attachments configured inside outlook mail in mac?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

Outlook web add-ins works for the Exchange accounts only. Non-exchange backed accounts are not supported.


Typically an array of AttachmentDetails objects is returned as the attachments property of an appointment or message item.

// The following code builds an HTML string with details
// of all attachments on the current item.
var item = Office.context.mailbox.item;
var outputString = "";

if (item.attachments.length > 0) {
    for (i = 0 ; i < item.attachments.length ; i++) {
        var attachment = item.attachments[i];
        outputString += "<BR>" + i + ". Name: ";
        outputString += attachment.name;
        outputString += "<BR>ID: " + attachment.id;
        outputString += "<BR>contentType: " + attachment.contentType;
        outputString += "<BR>size: " + attachment.size;
        outputString += "<BR>attachmentType: " + attachment.attachmentType;
        outputString += "<BR>isInline: " + attachment.isInline;
    }
}

console.log(outputString);
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda