2

In a uwp app, is it possible to show a Windows.UI.Xaml.Controls.Primitives.FlyoutBase object in relation to a particular point, as opposed to a FrameworkElement object?

In other words, instead of

flyout.ShowAt(some frameworkElement);

I want something like

flyout.ShowAt(some frameworkElement, x, y).

I realize I could create a dummy FrameworkElement and do it that way, then remove the dummy when the flyout is removed. But that seems a little heavyweight.

William Jockusch
  • 26,513
  • 49
  • 182
  • 323
  • 3
    This is for sure availabe with *MenuFlyout*, though seems like *FlyoutBase* lacks method showing at particular point. – Romasz Mar 07 '17 at 19:22

1 Answers1

-1

Romasz comment above had the correct answer. If the flyout is in fact a MenuFlyout, cast it to that class, then call.

Windows.Foundation.Point point = whatever;// your point here
menuFlyout.ShowAt(frameworkElement, point);
William Jockusch
  • 26,513
  • 49
  • 182
  • 323