Mailing List Archive

[ python-Bugs-1093389 ] mapitags.PROP_TAG() doesn't account for new longs
Bugs item #1093389, was opened at 2004-12-30 11:36
Message generated for change (Comment added) made by hildjj
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1093389&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Windows
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: Joe Hildebrand (hildjj)
Assigned to: Mark Hammond (mhammond)
Summary: mapitags.PROP_TAG() doesn't account for new longs

Initial Comment:
Test case:

>>> from win32com.mapi.mapitags import *
>>> PROP_TAG(PT_LONG, 0x8041)
2151743491L

Should be:
-2143223805L

or, alternately, the rest of the mapi interfaces should
know about unsigned ints.

----------------------------------------------------------------------

>Comment By: Joe Hildebrand (hildjj)
Date: 2005-09-19 17:43

Message:
Logged In: YES
user_id=101697

For example, you could use this (awful hack):

def PROP_TAG(ulPropType,ulPropID):
a = (ulPropID<<16)|(ulPropType)
if ulPropID & 0x8000:
a = int(-((a ^ 0xffffffff) + 1))
return a


mostly posted here so i can google for it next time...

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1093389&group_id=5470
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com