locked
How to close SettingsPane programmatically?

    Question

  • Hi Friends,

    In my Windows Store App I am showing SettingsPane with SettingsPane.Show().

    After doing some work now I want to close that but I am not getting any Method to close that.

    How can I close the SettingsPane after showing using SettingsPane.Show() using C# and XAML?

    Thursday, June 5, 2014 12:16 PM

Answers

  • Cheah,

    That isn't relevant to this post. Your code snippet adds a setting to the pane. It doesn't have anything to do with closing the pane. Please stop posting off-topic and then proposing your own posts with your sock-puppet account.

    As Jamles said, there is no direct way to do so, but since it is a Flyout you can set the focus elsewhere and it will close. Typically you would want to let the user control this rather than programmatically yanking it away from the user.

    --Rob

    Thursday, June 12, 2014 1:40 AM
    Owner
  • Hi Sandeep,

    Setting flyout is a good option with Hide() event, but why do you need programmatically dismiss it?

    If user click somewhere else in your app, the SettingPane will be closed automatically, if you really need a close function, then navigate to another page should be fine.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, June 11, 2014 2:35 AM
    Moderator

All replies

  • Could you use a settings flyout? SettingsFlyout.Hide()
    Thursday, June 5, 2014 12:38 PM
  • Hi Sandeep,

    Setting flyout is a good option with Hide() event, but why do you need programmatically dismiss it?

    If user click somewhere else in your app, the SettingPane will be closed automatically, if you really need a close function, then navigate to another page should be fine.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Wednesday, June 11, 2014 2:35 AM
    Moderator
  • Cheah,

    That isn't relevant to this post. Your code snippet adds a setting to the pane. It doesn't have anything to do with closing the pane. Please stop posting off-topic and then proposing your own posts with your sock-puppet account.

    As Jamles said, there is no direct way to do so, but since it is a Flyout you can set the focus elsewhere and it will close. Typically you would want to let the user control this rather than programmatically yanking it away from the user.

    --Rob

    Thursday, June 12, 2014 1:40 AM
    Owner