DOWNLOADFROMSTREAM Function (File)
Sends a file from a Microsoft Dynamics NAV Server to a RoleTailored client.
[Ok :=] DOWNLOADFROMSTREAM(VarInstream, DialogTitle, ToFolder, ToFilter, ToFile)
Parameters
- VarInStream
-
Type: variant
An InStream that you want to use to send the data in a file on Microsoft Dynamics NAV Server to a file on a RoleTailored client.
- DialogTitle
-
Type: text
The title that you want to display on the dialog box.
- ToFolder
-
Type: text
The name of the folder that is displayed in the dialog box.
- ToFilter
-
Type: text
The type of file that is displayed in the dialog box.
- ToFile
-
Type: variant
The name of the file that is displayed in the dialog box.
In the new architecture the business logic is run on the middle-tier server and not on the client.
This means that in Microsoft Dynamics NAV, files are created on the Microsoft Dynamics NAV service and not locally on the client computer as is the case in the Classic client. When you write code for the application, you must therefore remember where the files are created.
Use UPLOAD Function (File) and UPLOADINTOSTREAM Function (File) to send a file from a RoleTailored client to a Microsoft Dynamics NAV service.
Use DOWNLOAD Function (File) and DOWNLOADFROMSTREAM Function (File) to send a file from a Microsoft Dynamics NAV service to a RoleTailored client.
We recommend that you use the functions in Codeunit 419, 3-Tier Automation Mgt., to upload and download files.