Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8548003
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T13:23:39+00:00 2026-06-11T13:23:39+00:00

Currently developing an Outlook add-in with Add-in Express, I have to revert to some

  • 0

Currently developing an Outlook add-in with Add-in Express, I have to revert to some pure MAPI functions for reading MAPI properties.

Having this P/Invoke wrapper to the HrGetOneProp function:

[DllImport(@"MAPI32.DLL")]
static extern int HrGetOneProp(IntPtr pmp, uint ulPropTag, out IntPtr ppProp);

I’m trying to pass an Outlook attachment object of type IMAPIProp as the first parameter to the function.

what I’m currently failing in is how to “convert” that object to an IntPtr so that I can pass it as the first parameter to the function. I’ve tried to use Marshal.StructureToPtr but obviously this failed with an exception, since I am not passing a structure but rather just a reference to an unmanaged COM object.

So my question is:

How to successfully call the HrGetOneProp method with passing a COM object?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T13:23:40+00:00Added an answer on June 11, 2026 at 1:23 pm

    You want to use the Marshal.GetIUnknownForObject Method.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im currently developing a MVC application Framework and I have come for some advise
I'm currently developing an IE plugin using SpicIE . This plugin does some web
I am currently engaged in developing a add-in for MS outlook 2007. I need
I'm currently developing a toolbar for chrome and i have some issues with my
I am currently developing an Outlook add in that automatically creates a signature in
Currently developing an application using the newest version of symfony, obtained through PEAR. This
Currently developing a PHP framework and have ran into my first problem. I need
I am currently developing a private framework for use on WebKit devices. I have
I'm currently developing server side to Application, in the App I have a lot
Im currently developing a system where the user will end up having large arrays(

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.