To recover from an error with the QtmmSendMail Application Programming Interface (API), you should ensure that you are receiving error messages from the API on your workstation display.
If you code to return the error, then the program returns it to the program. However, if you set this value to 0, as shown in the following examples, then the error appears on your workstation display.
C example
Qus_EC_t Snd_Error_Code; Snd_Error_Code.Bytes_Provided=0;
RPG example
DAPIError DS D APIBytes 1 4B 0 D CPFId 9 15 C Eval APIBytes = 0