Downloads the specified file.
Namespace: DotNetNuke.Services.FileSystemAssembly: DotNetNuke (in DotNetNuke.dll)
Syntax
C# |
---|
public virtual void WriteFileToResponse( IFileInfo file, ContentDisposition contentDisposition ) |
Visual Basic |
---|
Public Overridable Sub WriteFileToResponse ( file As IFileInfo, contentDisposition As ContentDisposition ) |
Parameters
- file
- Type: DotNetNuke.Services.FileSystem..::..IFileInfo
The file to download.
- contentDisposition
- Type: DotNetNuke.Services.FileSystem..::..ContentDisposition
Indicates how to display the document once downloaded.
Implements
IFileManager..::..WriteFileToResponse(IFileInfo, ContentDisposition)
Exceptions
Exception | Condition |
---|---|
System..::..ArgumentNullException | Thrown when file is null. |
DotNetNuke.Services.FileSystem..::..PermissionsNotMetException | Thrown when permissions are not met. |