Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 256
  • Last Modified:

Dock form at top of screen across all applications

Hi

I want to create a "bar" at the top of my screen that is visible across all applications.

How can I do this?
0
zattz
Asked:
zattz
  • 2
1 Solution
 
Gene_CypCommented:
When you say across all applications, you mean other applications or applications/windows created by that same project?


0
 
Gene_CypCommented:
In any case, if I understood your question correctly, then try the following:

myForm.TopMost = true;
myForm.Locked = true;
myForm.StartPosition = System.Windows.Forms.FormStartPosition.Manual;

myForm.DesktopLocation = new Point(0,0); // if you want it at the top but not to hide your taskbar (if your taskbar is at the top)
myForm.Location = new Point(0,0); // if you want the form at the top no matter where your taskbar is
 
0
 
Mike TomlinsonMiddle School Assistant TeacherCommented:
That would technically put it above all windows...

...but if you want it to decrease the "client area" of the desktop so that when windows maximize they treat your app as part of the boundaries then you need to register it as an APPBAR:
http://msdn.microsoft.com/en-us/library/cc144177(VS.85).aspx
http://msdn.microsoft.com/en-us/library/bb762108(VS.85).aspx

Example:
http://www.experts-exchange.com/Programming/Languages/C_Sharp/Q_24059722.html
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now