Re: Invalid Argument to date encode

Giganews Newsgroups
Subject: Re: Invalid Argument to date encode
Posted by:  Don (kingfi…
Date: Mon, 28 Nov 2005

> When I use TIdPOP3 to recieve the mail, it shows a
> error "invalid argument to date encode", because the
> date of mail has chinese word, how can Iresolve the
> question.

Basically, you cannot.

According to RFC 2822, all date time values in message headers use the
English day and month name abbreviations and are represented using the
NetASCII character set.  No provision is made for localization of the values
or for multibyte character sets.  IOW, the message is malformed.

You could try retrieving the message using TIdPOP3 and by setting
TIdMessage.NoDecode to True.  When NoDecode is True, the entire message will
be retreived and stored in TIdMessage.Body.  No decoding based on Content
Types or Tranfer Encodings are performed for the message or its'
attachments.  Then, you'll have to process the message contents entirely on
your own.




In response to

Invalid Argument to date encode posted by Alex Dean on Mon, 28 Nov 2005