MessageUID Property  
 

Return the UID for the current message on the mail server.

Syntax

object.MessageUID

Remarks

The MessageUID property returns a string which uniquely identifies the message on the server. The identifier is assigned by the mail server, and retains the same value across multiple client sessions. This value is typically used when the client wants to leave a message on the mail server, but does not wish to retrieve the message contents multiple times. For example, the client can store the UID for each message that it retrieves, but does not delete from the server. The next time that it connects to the mail server, it compares the UID of a message against the stored values. If there is a match, the client knows that the message has already been retrieved, and does not need to do so again.

This property requires that the mail server support the optional UIDL command. If the command is not supported, this property will always return an empty string. Note that the UID for the message comes from the mail server and is not the same as the Message-ID header field in the message itself.

Data Type

String