How to close inline response

1k Views Asked by At

I want to close current Inline Response to do some behaviors.

I have try this function: OutlookApp.ActiveExplorer().ClearSelection() but it cannot work under Conversation View and raise exception:

The method you are invoking is invalid for a conversation view

So, what is right way to close Inline Response?

3

There are 3 best solutions below

0
On

Simply deleting the Response rather than discarding will work.

1
On

That functionality is not exposed for the programmatic access. You can try to use Accessibility API to simulate a click on the "Discard" button or you can try Redemption (I am its author) and its SafeExplorer object - it exposes ActiveInlineResponseDiscard method:

set sExplorer = CreateObject("Redemption.SafeExplorer")
sExplorer.Item = Application.ActiveExplorer
sExplorer.ActiveInlineResponseDiscard
0
On

The Outlook object model doesn't provide any property or method for that.

But you may use the Display method of the MailItem class to display a new Inspector object for the item. The InlineResponse editor will be closed in that case.

To get an instance of the MailItem class you need to use the ActiveInlineResponse property of the Explorer class which return an item object representing the active inline response item in the explorer reading pane.