[DialogResult] Add TryAgain and Continue (result 10, and 11) respectively.#4746
[DialogResult] Add TryAgain and Continue (result 10, and 11) respectively.#4746RussKie merged 13 commits intodotnet:mainfrom
Conversation
Codecov Report
@@ Coverage Diff @@
## main #4746 +/- ##
===================================================
- Coverage 97.97301% 97.95489% -0.01812%
===================================================
Files 543 548 +5
Lines 264728 266049 +1321
Branches 5007 5112 +105
===================================================
+ Hits 259362 260608 +1246
- Misses 4486 4547 +61
- Partials 880 894 +14
Flags with carried forward coverage won't be shown. Click here to find out more. |
src/System.Windows.Forms/src/System/Windows/Forms/MessageBox.cs
Outdated
Show resolved
Hide resolved
|
I don't believe we can add any unit tests here, but you can add a test app that exposes and features the new functionality to WinformsControlsTest project. Perhaps in a way similar to how we test "dialogs" or "task dialog" 🤔 |
|
I'm converting this to draft until we get tests. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
I pushed an alternative version to how we can test the With that I discovered what I also struggle to see how |
This comment has been minimized.
This comment has been minimized.
|
No, it doesn't look so. If you specify only 3 buttons but set the default button to 4, the app will crash. |
This comment has been minimized.
This comment has been minimized.
672407e to
6c31d7e
Compare
|
I rebased this on top of the current tip of main and removed the code parts that are in #4809 from this PR. |
Co-authored-by: Igor Velikorossov <RussKie@users.noreply.github.com>
Signed-off-by: AraHaan <seandhunt_7@yahoo.com>
Signed-off-by: AraHaan <seandhunt_7@yahoo.com>
|
@RussKie think the blocking label can be removed now? |
|
Yep :) |
|
Sweet this looks 👌 to merge with all checks passing. |
|
Thank you |

Resolves #4712.
Proposed changes
ShowCoreinMessageBoxclass to remove the need for theWin32ToDialogResultmethod.Customer Impact
TryAgainorContinuewas pressed specifically on a MessageBox.Regression?
No
Risk
Screenshots
Not sure if this is considered a UI change. Left it in case it is.
Before
After
Test methodology
Accessibility testing
Not sure if this is considered a UI change. Left it in case it is.
Test environment(s)
Microsoft Reviewers: Open in CodeFlow