PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Handling the messages and their attached files
  • Reminder
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Copies the attachment of current email onto the user computer (locally).
Versions 17 and later
iPhone/iPad This function is now available for the iPhone/iPad applications.
New in version 17
iPhone/iPad This function is now available for the iPhone/iPad applications.
iPhone/iPad This function is now available for the iPhone/iPad applications.
Versions 21 and later
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Versions 22 and later
Android Widget This function is now available in Android Widget mode.
Android This function is now available for the Android applications.
New in version 22
Android Widget This function is now available in Android Widget mode.
Android This function is now available for the Android applications.
Android Widget This function is now available in Android Widget mode.
Android This function is now available for the Android applications.
WINDEVReports and QueriesWindows MobileUser code (UMC)
FOR I = 1 TO Email.NbAttach
FileToSave = fSelect(("", "", "Name of the file to save", ...
"All files (*.*)" + TAB + "*.*", "", fselCreate)
EmailSaveAttachment(Email.Attach[I], FileToSave)
END
WINDEVWEBDEV - Server codeReports and QueriesJavaAjaxUser code (UMC)
sAttachmentDir is string = ...
CompleteDir(SysDir(srCommonAppData)) + "MyProject\Attachements\"
IF NOT fDirectoryExist(sAttchmentDir) THEN fMakeDir(sAttachmentDir)

FOR I = 1 TO Email.NbAttach  
IF NOT EmailSaveAttachment(Email.Attach[I]), ...
sAttachmentDir + Email.Attach[I]) THEN Error(ErrorInfo())
END
Syntax
Versions 15 and later
WINDEVWEBDEV - Server codeReports and QueriesAndroidAndroid Widget iPhone/iPadWindows MobileUniversal Windows 10 AppAjaxUser code (UMC)

Saving a file attached to an emailAttach variable Hide the details

<Result> = EmailSaveAttachment(<Attached file> , <Name of Copied File>)
<Result>: Boolean
  • True if the attached file was copied onto the local computer.
  • False otherwise. To find out the error details, use ErrorInfo associated with the errMessage constant.
<Attached file>: emailAttach variable
Name of emailAttach variable containing the description of attached file.
<Name of Copied File>: Character string (with quotes)
Name and full or relative path of file copied onto the local computer.
New in version 15
WINDEVWEBDEV - Server codeReports and QueriesAndroidAndroid Widget iPhone/iPadWindows MobileUniversal Windows 10 AppAjaxUser code (UMC)

Saving a file attached to an emailAttach variable Hide the details

<Result> = EmailSaveAttachment(<Attached file> , <Name of Copied File>)
<Result>: Boolean
  • True if the attached file was copied onto the local computer.
  • False otherwise. To find out the error details, use ErrorInfo associated with the errMessage constant.
<Attached file>: emailAttach variable
Name of emailAttach variable containing the description of attached file.
<Name of Copied File>: Character string (with quotes)
Name and full or relative path of file copied onto the local computer.
WINDEVWEBDEV - Server codeReports and QueriesAndroidAndroid Widget iPhone/iPadWindows MobileUniversal Windows 10 AppAjaxUser code (UMC)

Saving a file attached to an emailAttach variable Hide the details

<Result> = EmailSaveAttachment(<Attached file> , <Name of Copied File>)
<Result>: Boolean
  • True if the attached file was copied onto the local computer.
  • False otherwise. To find out the error details, use ErrorInfo associated with the errMessage constant.
<Attached file>: emailAttach variable
Name of emailAttach variable containing the description of attached file.
<Name of Copied File>: Character string (with quotes)
Name and full or relative path of file copied onto the local computer.

Saving a file attached to the Email structure Hide the details

<Result> = EmailSaveAttachment(<Name of Attached File> , <Name of Copied File>)
<Result>: Boolean
  • True if the attached file was copied onto the local computer.
  • False otherwise. To find out the error details, use ErrorInfo associated with the errMessage constant.
<Name of Attached File>: Character string (with quotes)
Logical name of attached file, obtained in the Email.Attach variable.
<Name of Copied File>: Character string (with quotes)
Name and full or relative path of file copied onto the local computer.
Remarks

Handling the messages and their attached files

We recommend that you save the messages and their attached files on the local drive (or on a server drive), then delete them from the server. This operation is used to:
  • reduce the size of the mailbox on the server,
  • improve and speed up the communications: only the new messages will be read on the server.

Reminder

Email structure: The following variables contain information about the files attached to the current message:
  • Email.NbAttach: number of attachments.
  • Email.Attach: array containing the name of the files attached to the current message.
Email variable: The files attached to the current message are returned by Email..Attach (array containing the name of the files attached to the current message).
Components
WINDEVWEBDEV - Server codeReports and Queries wd230com.dll
Windows Mobile wp230com.dll
Java wd230java.jar
Linux wd230com.so
Android wd230android.jar
Minimum required version
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment