Skip to content

Commit

Permalink
Fixing UI test app x-thread exception (port 6.0) (#5972)
Browse files Browse the repository at this point in the history
  • Loading branch information
vladimir-krestov authored Oct 15, 2021
1 parent 32a7070 commit 1eab25c
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
using System.Windows.Forms;
using WinformsControlsTest;

// Set STAThread
Thread.CurrentThread.SetApartmentState(ApartmentState.Unknown);
Thread.CurrentThread.SetApartmentState(ApartmentState.STA);
ApplicationConfiguration.Initialize();

Application.SetUnhandledExceptionMode(UnhandledExceptionMode.ThrowException);
Expand Down

0 comments on commit 1eab25c

Please sign in to comment.