I try to open a WPF window containing my WPF user control on LinaPad.
var w = new System.Windows.Window() { Content = myControl };
w.ShowDialog();
This code works only for the first time execution after opening a query tab. If I execute the code again, then it throw InvalidOperationException saying
Cannot use a DependencyObject that belongs to a different thread than its parent Freezable
Is there any difference between the first time execution environment and the later execution environment in LinqPad?