[python-win32] python3 and extended mapi
Christian K.
ckkart at hoc.net
Mon Jun 9 20:53:48 CEST 2014
<Paul_Koning <at> Dell.com> writes:
>
>
> On Jun 9, 2014, at 9:07 AM, Christian K. <ckkart <at> hoc.net> wrote:
>
> > Hi,
> >
> > I was very pleased to see that retrieving properties of a MAPI object yields
> > either a <str> or <bytes> type depending on whether the _A or _W property
> > was queried …
>
> Really? That seems strange. As I recall, the *_W APIs are “wide
character” ones. So in Python 3, they
> should both map to <str> type. <bytes> applies only to non-text data.
At least for text properties like e.g. PR_SUBJECT_A / _W the former returns
a mbcs encoded "string", i.e. of bytes type and the latter a 2-byte unicode
string. Binary properties are always returned as bytes in contrast to
earlier when using pyrhon2.
Chrisrian
More information about the python-win32
mailing list