Updating Form Region Header Text

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

Updating Form Region Header Text
 
John Di Grazia




Posts: 3
Joined: 2011-05-23
Hi,

Isn't possible to update the header text of a form region without resorting to using a custom header? I've been trying to do this for my Outlook plugin

When the form region is initially loaded, it is in maximized mode and the header text will contain the text "My Plugin". When I minimize, I want to change the header text to "My Plugin is disabled", so I thought the best way to do this was to do it in the Deactivate event

eg.

[CODE]
void myOlForm_Deactivate(object sender, EventArgs e) {
this.Text = "My Plugin is disabled";
}
[CODE]

This doesn't seem to work. I traced it and it is definitely executing the event, but somehow the form isn't refreshing?
Posted 23 May, 2011 21:58:39 Top
Fedor Shihantsov


Guest


Hi John,

It works on my side. I use the Activated and Deactivate events (see the code below). The header text is changed when I change the state of a region.

        private void ADXOlForm1_Deactivate(object sender, EventArgs e)
        {
            this.Text = "My Plugin is disabled";
        }

        private void ADXOlForm1_Activated(object sender, EventArgs e)
        {
            this.Text = "My Plugin";
        }

What version of Add-in Express do you use?
Posted 24 May, 2011 07:14:50 Top
John Di Grazia




Posts: 3
Joined: 2011-05-23
I'm using Version 6.3 Release (build 3052)
Posted 24 May, 2011 20:51:13 Top
Eugene Astafiev


Guest


Hi John,

Please note that you use an old build of Add-in Express 2010. You can download the latest build from http://www.add-in-express.com/downloads/adxnet.php. Then please don't forget to replace the adxloader.dll in the Loader folder of your project with a new one (see the Redistributables folder). Does it help?
Posted 25 May, 2011 03:12:22 Top
John Di Grazia




Posts: 3
Joined: 2011-05-23
Thanks, that works fine after upgrade.

Cheers,
Posted 26 May, 2011 08:23:29 Top
Eugene Astafiev


Guest


You are welcome, John!
Posted 26 May, 2011 08:40:56 Top