Skip to content

UnhandledException for NumberBox SpinButtonPlacementMode.Compact when opening in a window twice in WinAppSDK >= 1.6.240829007 #5546

Closed
@TRadigk

Description

@TRadigk

Describe the bug

Hi,
there is a very easy to run reproduction repository for this issue:
https://github.com/TRadigk/NumberBoxCrashRepro

Please see the provided steps to reproduce the bug.

Packaged/NonPackaged makes no difference. The issue is found in 1.6.240829007 and newer, not present in earlier versions.

Unfortunately I am not able to debug any further than "invalid parameter" being found in the unhandled exception, which is not helpful.

Steps to reproduce the bug

  1. Clone the repository.
  2. Open the solution in Visual Studio.
  3. Build the solution.
  4. Run the application.
  5. Click the "Click Me" button on first window.
  6. Click the number zone in the NumberBox in the new window (so that the flyout with the spin buttons is shown at least once)
  7. Close the secondary window
  8. Click the "Clicked" button on first window.

Expected behavior

App behaves the same with Inline or Hidden setting.
or
App behaves the same as with using WinAppSDK 1.5.250108004.

Screenshots

No response

NuGet package version

WinUI 3 - Windows App SDK 1.7.0: 1.7.250310001

Windows version

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions