-5

I want to create a WPF application that is always docked on the right side of the screen.
I want it to act like the windows 8 charms bar.

The bar shouldn't be visibile on default but only when the mouse of the user comes to the right side of the screen.

How can I achieve this ?

I want to run this application on vista/windows 7

Example of charmbar : enter image description here

Robby Smet
  • 4,649
  • 8
  • 61
  • 104

1 Answers1

0

•You can place window of your application to right of the screen. Then you need to handle events when mouse enters (MouseEnter) and leaves (MouseLeave) the form to move the form up and down. •You can use a background thread to call GetCursorPos method at a set interval (i.e. each 500ms) second to check where currently the mouse is. See this link for more information about it and a sample code: http://www.pinvoke.net/default.aspx/user32.getcursorpos. (If you need only to check the mouse position, you can use a timer to simplify you application.)

From:

Create a dock like application using C# and wpf

To get sliding effect follow

how to show a window with sliding effect from right to left in WPF

And to position your window:

How to set the location of WPF window to the bottom right corner of desktop?

Moral of the story

Stop asking questions that have already been asked many time.

Community
  • 1
  • 1
Mayank
  • 8,777
  • 4
  • 35
  • 60