Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- protected void T(object obj)
- {
- Window w = new Window() { Width = 1024, Height = 768 };
- w.Show();
- Thread.Sleep(1000);
- w.Close();
- }
- private void Something()
- {
- Thread t = new Thread(new ParameterizedThreadStart(T));
- t.SetApartmentState(ApartmentState.STA);
- t.Priority = ThreadPriority.Normal;
- t.Start();
- GC.Collect();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement