WPF Reflections

Jan 16 2008   11:59PM GMT

Popup box

Mark Shurmer Profile: MarkWPF

One thing that I have noticed, out there in the real world, is that people new to WPF haven’t noticed the (slightly) unsung hero Popup.
I have actually seen people spending man weeks recreating a floating window as per the popup control in WPF.

So what is it? Well it is the ancestor class for menus, tooltips and the combobox – and provides the necessary floating behaviour.

An example of using it is:

<ListBox Name=”xxx” />
<Popup PopupAnimation=”Fade” Placement=”Mouse” x:Name=”pop”>
<TextBlock Text=”ggggg” />

This example will show a floating window at the mouse cursor, when the mouse is in the stackpanel. Easy as pie isn’t it?

 Comment on this Post

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

Share this item with your network: