Download large size [26MB] zipped file from email using MS365 SCOPE

Hi Team,

I am working on project where I am using Microsoft Office 365 Scope activity as shown in the figure below.

I am using get mails activity to fetch the mail from mailbox [working perfectly]
In my case I am just extracting one email and this email has only one activity. So my scenario is very easy. But still facing issues.

Get Mail : output = out_office363_OutputMails of type office365MailMessage
Since I have only one mail to be used : I used index (0) to identify this mail

Also, I can refer the attachment as office365Message_OutputMails(0).Attachment(0)
Since I have only one mail attachment to this mail.

Now I just want to download that one mailattachment to the folder location as shown in the figure.

The zipped file attached to this mail is downloaded to the location. However the original filezise is 26MB. However, the downloaded file size is 400KB and cannot be opened or unzipped.

I tried using VB.Net code, C# code, Save attachment activity. But got exact same results.

PLease help experts : @Anil_G @ashokkarale @Yoichi

@hacky,

Downloading the bigger attachment will take some time to download it fully. Add a retry scope to keep checking for the file is downloaded fully or not and then try opening it after download.

How can I do that in UiPath. Can you please elaborate?

I tried VB.Net and C# Code. also Save attachment activity

@hacky,

I observed you are using incorrect activity to download the attachment. You should be using Download Email Attachments activity

This will give you array of type O365AttachmentLocalItem. Here you don’t have option to specify where to download the attachment.

You can get the downloaded file path with this code:

localAttachments(0).LocalPath

@ashokk But I am not able to use the activity provided by you. Due to some issues with connection string.