activities
latest
false
UiPath logo, featuring letters U and I in white

Productivity activities

Last updated Mar 13, 2026

DownloadFile

Downloads a file from OneDrive or SharePoint.

Namespace: UiPath.MicrosoftOffice365.Activities.Api

Assembly: UiPath.MicrosoftOffice365.Activities.Api (in UiPath.MicrosoftOffice365.Activities.Api.dll)

Syntax

Stream DownloadFile(
	IFile file,
	bool convertToPdf = false
)
Stream DownloadFile(
	IFile file,
	bool convertToPdf = false
)

Parameters

file IFile : The file to download.

convertToPdf Boolean (Optional) : Indicates whether to convert the file to PDF format. Only files of the following types can be converted: csv, doc, docx, odp, ods, odt, pot, potm, potx, pps, ppsx, ppsxm, ppt, pptm, pptx, rtf, xls, xlsx.

Return value

Stream - The file stream.

  • Syntax
  • Parameters
  • Return value

Was this page helpful?

Connect

Need help? Support

Want to learn? UiPath Academy

Have questions? UiPath Forum

Stay updated