form at front

1897
2
04-27-2016 11:02 AM
martinjabbour
New Contributor

Hi,

How can I keep a form in vb.net Arcobject in front of arcmap always ?

0 Kudos
2 Replies
FreddieGibson
Occasional Contributor III

If the form is modal it should always appear on top. If the form is modeless you should be able to set the TopMost property to true, which should keep it on top.

How to: Keep a Windows Form on Top

0 Kudos
KenBuja
MVP Esteemed Contributor

You can also use this code when showing the form to set its owner as the ArcMap application

MyFormInstanceName.Show(System.Windows.Forms.Control.FromHandle(My.ArcMap.Application.hWnd))