引用:
private void button3_Click(object sender, EventArgs e)
{
System.Threading.Thread s = new System.Threading.Thread(new System.Threading.ThreadStart(test));
s.ApartmentState = System.Threading.ApartmentState.STA;
s.Start();}
public void test()
{
FolderBrowserDialog browseDialog = new FolderBrowserDialog();
browseDialog.ShowDialog();
string selectPath = browseDialog.SelectedPath;
textBox2.Text = selectPath;
}
private void textBox2_TextChanged(object sender, EventArgs e)
{
}
----------------------------------