Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
325
What Causes a Newly Added ContentPane to Fail on Activate()?
posted

We have a TabGroupPane we have added a ContentPane to. After adding the ContentPane, we call ContentPane.Activate() which should cause th ContentPane to become the SelectedItem in the TabControl. However, it fails. What causes this behavior? I've tried setting focus to the main window prior to Activate().

- jeremiah

Parents
No Data
Reply
  • 54937
    Offline posted

    The kinds of things that come to mind are if it cannot receive keyboard focus (i.e. the element or one of its ancestors is not visible or in the visual tree) or if something else takes focus away after it got it. Can you provide a project that reproduces the issue so we can see what is happening? Does it make a difference if you asynchronously activate it (e.g. call Dispatcher.BeginInvoke)?

Children
No Data