Sending / Retrieving information in the adjoining form

Add-in Express™ Support Service
That's what is more important than anything else

Sending / Retrieving information in the adjoining form
 
Sujay Ghosh




Posts: 27
Joined: 2010-01-20
Hello

I have developed an adjoining form for the Outlook inspector, please refer image [img]https://ctrlv.link/rNIc[/img]

My question is how to send / retrieve data from the adjoining region. I have an a separate class for the controls, but not sure how do I store and retrieve data from the controls, as they are not a part of Outlook.

Please help .

Thank you
Sujay
Posted 08 Nov, 2022 10:59:03 Top
Andrei Smolin


Add-in Express team


Posts: 18817
Joined: 2006-05-11
Hello Sujay,

An adjoining form? We don't use this term; as far as I remember this term originates from VSTO. Add-in Express forms descend from ADXOlForm. Is this your case? If so, you get the form instance shown in the given Outlook window by calling ADXOlFormsCollectionItem.GetForm(). See also section Form region instancing; see the PDF file in the folder {Add-in Express}\Docs on your development PC.

To send the email, get the MailItem opened in the inspector window and call MailItem.Send(). If your form is an ADXOlForm shown in the inspector window, you get the corresponding Inspector object via ADXOlForm.InspectorObj. You call Inspector.CurrentItem to get the mail item.

Regards from Poland (GMT+1),

Andrei Smolin
Add-in Express Team Leader
Posted 09 Nov, 2022 04:21:16 Top
Sujay Ghosh




Posts: 27
Joined: 2010-01-20
Hello Andrei ,

Thank you for the explanation.

You are correct, I have used the ADXOLForm class; and adjoining region is the VSTO term .

I shall follow your notes .

Thank you
Sujay
Posted 09 Nov, 2022 11:52:29 Top
Sujay Ghosh




Posts: 27
Joined: 2010-01-20
Hello Andrei

I read through the documentation , but cant understand how to get the ADXOlForm.InspectorObj. Can you provide a short example for achieving this
Posted 10 Nov, 2022 11:33:56 Top
Andrei Smolin


Add-in Express team


Posts: 18817
Joined: 2006-05-11
Hello Sujay,

Let an ADXOlForm show in Inspector windows. Put a button on the form. In the button's Click event call this.InspectorObj (C#) or Me.InspectorObj (VB.NET). Cast the result to Outlook.Inspector.

If you do this in an ADXOlForm shown in an Explorer window, the InspectorObj property returns null.

Regards from Poland (GMT+1),

Andrei Smolin
Add-in Express Team Leader
Posted 11 Nov, 2022 04:42:25 Top