InetPop3GetMessageInfo
int InetPop3GetMessageInfo (int POP3Handle, int messageIndex, int numberOfLines, char **from, char **to, char **cc, char **subject, char **body);
Purpose
Returns information in a POP3 email message.
Parameters
Input | ||||
Name | Type | Description | ||
POP3Handle | int | A POP3 handle returned by the InetPop3Open function. | ||
messageIndex | int | The zero–based index of a message on the POP3 server. | ||
numberOfLines | int | The number of lines of the message body to retrieve. Pass –1 to retrieve the entire message body.
|
||
Output | ||||
Name | Type | Description | ||
from | char * | The value of the "From" field in the email message. Pass the address of a char* variable to hold the value. This function allocates memory for the value. You must discard this memory by calling the InetFreeMemory function. If you do not want this value, you can pass NULL for this parameter. | ||
to | char * | The value of the "To" field in the email message. Pass the address of a char* variable to hold the value. This function allocates memory for the value. You must discard this memory by calling the InetFreeMemory function. If you do not want this value, you can pass NULL for this parameter. | ||
cc | char * | The value of the "Cc" field in the email message. Pass the address of a char* variable to hold the value. This function allocates memory for the value. You must discard this memory by calling the InetFreeMemory function. If you do not want this value, you can pass NULL for this parameter. | ||
subject | char * | The value of the "Subject" field in the email message. Pass the address of a char* variable to hold the value. This function allocates memory for the value. You must discard this memory by calling the InetFreeMemory function. If you do not want this value, you can pass NULL for this parameter. | ||
body | char * | The body of the email message. Pass the address of a char* variable to hold the value. This function allocates memory for the value. You must discard this memory by calling the InetFreeMemory function. If you do not want this value, you can pass NULL for this parameter.
|
Return Value
Name | Type | Description |
result | int | Return value indicating whether the function was successful. A negative number indicates that an error occurred. |
Additional Information
Library: Internet Library
Include file: cvintwrk.h
LabWindows/CVI compatibility: LabWindows/CVI 7.1 and later
Example
Refer to internet\pop3clnt\pop3clnt.cws for an example of using the InetPop3GetMessageInfo function.