Problems when displaying Windows Forms in OneNote 2007 add-in

D

dyowee

Good day!
I wrote an add-in for OneNote 2007 in which I pop-up a main form when the
button is clicked. One of my problem is that the form is always minimized
when I clicked the add-in button. In my main form, I have a menus. When I
click on these menus, the menu items are left on the screen even when the
main menu items are closed. I also have sub forms that I show when a button
is clicked from the main form. When I closed the sub form, it stays on the
screen behind the main form. But the sub form is not really there, but it
seems that screen was not refreshed. I have done some Windows Forms
programming for a few years now, so I'm confused why these are occuring. I
hope you can help me out. Thanks.
 
J

John Guin [msft]

Do those errors occur if you run your app outside of OneNote?

You may also want to check out a couple of my blog articles. First, the
overview of a bunch of powertoys the test team wrote:
http://blogs.msdn.com/johnguin/arch...te-powertoys-from-the-test-team-for-2007.aspx

Most have code with them.

Also, check out the entry at
https://blogs.msdn.com/johnguin/archive/2007/12/20/how-to-create-a-floating-toolbar-in-onenote.aspx

Neat the end of it is a tip to help make sure your windows get focus the way
you want them to.
 
D

dyowee

Thank you very much for your response. My form is not anymore minimized. =)
I tried to create a similar toolbar like your "floating toolbar", but when I
show the toolbar in OneNote from an add-in button click, it looks different
from the design in Visual Studio. The images for the buttons aren't aligned
MiddleCenter, more like BottomRight. =( Any suggestions?

Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top