none
How can I disable the "Forward" Button? RRS feed

  • Question

  • Outlook.Application objApplication = Globals.ThisAddIn.Application;

    Outlook.MailItem objMailItem = objApplication.ActiveExplorer().Selection[1];

    objMailItem.AlternateRecipientAllowed = false;

    objMailItem.RecipientReassignmentProhibited = true;

    I try to make an plug in in Outlook by VSTO.

    This plug in can disable the "Forward" function.

    But it's not working.

    And I find this research.microsoft.com/en-us/projects/researchdesktop/noreplyall.aspx

    Does anybody know how to do that?

    Monday, March 18, 2013 2:59 AM

Answers

  • Hi Vinc,

    you can use the following code to disable "Forward" button, I have test on my machine and it work fine for me.

    Outlook.MailItem mailItem = Globals.ThisAddIn.Application.ActiveExplorer().Selection[1];
                if (mailItem != null)
                {
                   
                    mailItem.Actions["Forward"].Enabled = false;
                }
    Thanks.

    • Marked as answer by Vincentc.tw Monday, March 18, 2013 6:19 AM
    Monday, March 18, 2013 6:11 AM

All replies

  • Hi Vinc,

    you can use the following code to disable "Forward" button, I have test on my machine and it work fine for me.

    Outlook.MailItem mailItem = Globals.ThisAddIn.Application.ActiveExplorer().Selection[1];
                if (mailItem != null)
                {
                   
                    mailItem.Actions["Forward"].Enabled = false;
                }
    Thanks.

    • Marked as answer by Vincentc.tw Monday, March 18, 2013 6:19 AM
    Monday, March 18, 2013 6:11 AM
  • It works fine.

    Thanks a lot.

    Monday, March 18, 2013 6:20 AM