????? ??????? ??????? ??????? ???? ??????? "???? ?????? ???? ???????" ??? ????? ?????? ?????????? ?????? ?????? ?????????? ????????? ?????? ?? ?????? Outlook 2003

?????? ????????? ?????? ?????????
???? ???????: 912237 - ??? ???????? ???? ????? ????? ??? ???????.
??? ????? ??? ???????. ????? "??? ??" ??? ??? ??????? ??? ????.
????? ???? | ?? ????

?? ??? ??????

????? ???

???? ???????? ??????? ???? ?? Microsoft Office Outlook 2003 Service Pack 2 (SP2) ??? ??? ?? ????????? ??????? ?? Microsoft Outlook. ???? ??? ??????? ????? ??????? ??????? ??????? ???? ??????? "???? ?????? ???? ???????" ??? ????? ?????? ?????????? ?????? ?????? ?????????? ????????? ?????? ?? Outlook 2003 SP2.

??????? ????

??? ???? ???????? ???????

???? "???? ???????? ?????" ???? ??? ??????? ?? Outlook 2003 SP2 ?? contab32.dll. ???? ??? ?????? ??????? ?? ???? "???? ?????" ?? ????? "???? ?????? ???? ???????". ???? ??? ?????? ???? ???? ??????? ???? ??????? ?? "???? ???????? ??? ?????" ?????? ?????? ?????????? ?????. ??? ????? ???? ???? ??????? ???? ????? ??? ????? ???? ???????? ?? ??? ???? ?? "???? ????????" ??????? ?????? ????? ????? ?????? ??? ??? ?????? "??" ????? ?????? ??????????. ???? ?? ???? ??? ????? ?????? ?????? ?????????? ??? ????? ?????? ????? ????? ?? ???? ???? ????? ?? ??? ?? ???? ??????? ?????? ??? ??? ??? ??????? ?????? ?? "???? ???????? ???????".

??? ??? ????? ??????? "???? ?????? ???? ???????" ??? ????? ?????? ??????????

????????? ???????? ?? ????? "??? ????? ???? ????????" ?? ?????? ????? ?? ??????? ?????? ?? ????? ?????? ?????????? ??????? ??? ??? ???????. ???? ??????? ???? CONTAB_ENTRYID ??????? ?????? ????? "???? ???????? ???????" ??? ?????? ????? ?????.

?????
#pragma pack(4)
typedef struct _contab_entryid
{
  BYTE misc1[4];
  MAPIUID misc2;
  ULONG misc3;
  ULONG misc4;
  ULONG misc5;
  // EntryID of contact in store.
  ULONG cbeid;
  BYTE abeid[1];
} CONTAB_ENTRYID, *LPCONTAB_ENTRYID;
#pragma pack()
CONTAB_ENTRYID ???? ????? ????? ?????? ?????? IMailUser ??????? ???? ??? ????????? ?? "???? ????????" ??? ?????. ????? ?????? ??? ??????? ????? ??? ????? ?? ???? ?? ?? ?? ??????? ???????:
  • ???? PR_ENTRYID ???? ??????? "???? ?????? ???? ???????"
  • ??????? PR_ENTRYID ?????? IMailUser ???? ??? ???? ?? "???? ????????" ??? ?????
???? ??????? ??????? typecast ???? ??????? "???? ?????? ???? ???????" ??? ??? ??????. ?? ?????? ????? cbeid ? abeid ??? ?? ???? ??????? ????? ???? ???????.

?????????? Microsoft ??????? ???????? ??? ??? ?? ???? ??????? ?? ?? ?????. ??? ????? ???? ?? ????? ??? ???????? ??????? ?????? ???????? ?? ???????? ???? ????. ????? ??? ??????? ???? ?????? ?? ??? ??????? ???? ??? ????? ?? ??????? ???? ??? ????????? ?????? ?????? ?????????. ???? ??????? ????? ??? Microsoft ??? ????? ????? ???? ???? ?? ?????? ?????? ??? ??????? ?????? ????? ?????? ?? ????? ??????? ?????? ??????? ?????.
HRESULT HrOpenContact(
  LPMAPISESSION lpSession,
  ULONG cbEntryID,
  LPENTRYID lpEntryID,  
  ULONG ulFlags,
  LPMESSAGE* lpContactMessage)
{
  ULONG ulObjType = NULL;
  if (sizeof(CONTAB_ENTRYID) > cbEntryID)
      return MAPI_E_INVALID_PARAMETER;
  LPCONTAB_ENTRYID lpContabEID = (LPCONTAB_ENTRYID) lpEntryID;
  HRESULT hRes = lpSession->OpenEntry(
      lpContabEID->cbeid,
      (LPENTRYID) lpContabEID->abeid,
      NULL,
      ulFlags,
      &ulObjType,
      (LPUNKNOWN*) lpContactMessage);
  return hRes;
}

??? ??? ????? ??????? "???? ?????? ???? ???????" ?????? ?????? ??????????

??????? ??????? ?????? ??? ?????? ?????? ?????????? ?? ????? "???? ?????? ???? ???????" ?? ???? ??????? ??????? ??? ??????? ???????. ????? ??????? ??? ????? ??????? ???. ?? ????? Outlook 2003 ???? ??????? ??? ??? ???????.

???????
DEFINE_OLEGUID(PSETID_Address, MAKELONG(0x2000+(0x04),0x0006),0,0);
#define dispidEmailAddrType 0x8082
#define dispidEmailEmailAddress 0x8083
#define dispidEmail2AddrType 0x8092
#define dispidEmail2EmailAddress 0x8093
#define dispidEmail3AddrType 0x80A2
#define dispidEmail3EmailAddress 0x80A3
DEFINE_OLEGUID(PSETID_Address, MAKELONG(0x2000+(0x04),0x0006),0,0); #define dispidEmailAddrType 0x8082 #define dispidEmailEmailAddress 0x8083 #define dispidEmail2AddrType 0x8092 #define dispidEmail2EmailAddress 0x8093 #define dispidEmail3AddrType 0x80A2 #define dispidEmail3EmailAddress...?????????

????? ??????? ??????? ?????? ???? MAPINAMEID. ????? ??? ??????? ???? ?????? ?? ??????.
?? ??? ??????????? ??? ??????
???????
PSETID_AdresslpGuid
mnid_idulKind
dispid??????
??? ??? ?? ???? MAPINAMEID ??????? ??????? GetIDsFromNames ?????? ??? ??????? ??????? ?????? ??? ???????. ????? ??? ???? ????? ???????.

?????????? Microsoft ??????? ???????? ??? ??? ?? ???? ??????? ?? ?? ?????. ??? ????? ???? ?? ????? ??? ???????? ??????? ?????? ???????? ?? ???????? ???? ????. ????? ??? ??????? ???? ?????? ?? ??? ??????? ???? ??? ????? ?? ??????? ???? ??? ????????? ?????? ?????? ?????????. ???? ??????? ????? ??? Microsoft ??? ????? ????? ???? ???? ?? ?????? ?????? ??? ??????? ?????? ????? ?????? ?? ????? ??????? ?????? ??????? ?????.
HRESULT HrGetEmail1(LPMESSAGE lpContact)
{
  HRESULT hRes = S_OK;
  LPSPropTagArray lpNamedPropTags = NULL;
  MAPINAMEID NamedID = {0};
  LPMAPINAMEID lpNamedID = &NamedID;
  NamedID.lpguid = (LPGUID)&PSETID_Address;
  NamedID.ulKind = MNID_ID;
  NamedID.Kind.lID = dispidEmailEmailAddress;
  hRes = lpContact->GetIDsFromNames(
      1,
      &lpNamedID,
      NULL,
      &lpNamedPropTags);
  if (SUCCEEDED(hRes) && lpNamedPropTags)
  {
      SPropTagArray sPropTagArray;
      sPropTagArray.cValues = 1;
      sPropTagArray.aulPropTag[0] = CHANGE_PROP_TYPE(lpNamedPropTags->aulPropTag[0],PT_STRING8);
      LPSPropValue lpProps = NULL;
      ULONG cProps = 0;
      hRes = lpContact->GetProps(
        &sPropTagArray,
        NULL,
        &cProps,
        &lpProps);
    if (SUCCEEDED(hRes) &&
      1 == cProps &&
      lpProps &&
      PT_STRING8 == PROP_TYPE(lpProps[0].ulPropTag) &&
      lpProps[0].Value.lpszA)
      {
          printf("Email address 1 = \"%s\"\n",lpProps[0].Value.lpszA);
      }
    MAPIFreeBuffer(lpProps);
    MAPIFreeBuffer(lpNamedPropTags);
  }
  return hRes;
}

??? ????? ??????? "???? ???????? ???????" ?????

????? Outlook ???? ????? ??? ??? ?????. ??? ????? ??? ?????? ????? ?? ????? ???????. ?????? ?? ???? ????? ??? ?????? ??????? ??????? PR_ATTACHMENT_CONTACTPHOTO. ????? ?????? ??? ????? ????? ???. ?? ????? Outlook ???? ??????? ??? ??? ???????.

?????

#define PR_ATTACHMENT_CONTACTPHOTO PROP_TAG( PT_BOOLEAN, 0x7FFF)
?????????

???? ?????? ??? ????? PR_ATTACHMENT_CONTACTPHOTO ????? ?? ?????? ?????? ??? ?????? ????? ?? ???? IMessage::GetAttachmentTable. ??? ?????? ??? ??????? PR_ATTACHMENT_CONTACTPHOTO ?????? ??? ???? IAttach. ??? ???? ???? ??????? PR_ATTACHMENT_CONTACTPHOTO ??????? ????? ?????? ??? ???? ??? ???????. ??? ????? ?????? ???? .jpeg. ??????? ?????? MAPI ????????? ??????? ??? ?????? ??? ???.

?????

????? ?? ?????????? ?? ?????? ????? Microsoft ??????? ??? ?????:
http://msdn2.microsoft.com/en-us/library/bb905282.aspx
http://msdn2.microsoft.com/en-us/library/bb820925.aspx
http://msdn2.microsoft.com/en-us/library/bb821181.aspx

???????

???? ???????: 912237 - ????? ??? ??????: 07/???? ??????/1435 - ??????: 2.1
????? ???
  • Microsoft Office Outlook 2003, ????? ?????? ??:
    • Microsoft Office 2003 Service Pack 2
????? ??????: 
kbnosurvey kbarchive kbmt kbhowto KB912237 KbMtar
????? ????
???: ??? ????? ??? ?????? ???????? ?????? ????? ???? ????? ?????????? ????? ?? ????????? ?????? ????. ???? ???? ?????????? ???? ?? ???????? ???????? ?????? ????????? ????? ????????? ???????? ????? ???????? ?????? ?? ?????? ??? ?? ???????? ???????? ?? ????? ??????? ?????? ??? ??????? ?????? ??. ?????? ?? ???? ??? ??????? ???????? ????? ?? ???? ????? ?????? ??? ????? ??? ????? ??????? ?? ????? ?? ?????? ??? ??? ??????? ??????? ?? ????? ????? ????? ????? ?????. ?? ????? ???? ?????????? ??????? ??? ????? ?? ??????? ?? ????? ?????? ?? ??? ????? ?? ????? ??????? ?? ???????? ?? ??? ???????. ???? ???? ?????????? ???????? ??? ????? ?????? ??????? ??????
???? ??? ????? ??????? ?????? ??????????912237

????? ???????

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com