我的情况:
void Installer1_AfterInstall(object sender, InstallEventArgs e)
{
try
{
MainWindow ObjMain = new MainWindow();
ObjMain.Show();
}
catch (Exception ex)
{
Log.Write(ex);
}
}
我收到了一个错误信息:“The calling thread must be STA, because many UI components require this”
我该怎么办?