同時実行エラーが発生しないように、+5 スレッドを同期的に作成しようとしています。
コード:
System.Threading.Thread t = new System.Threading.Thread(proc);
t.Start();//==t.BlueScreen();
t.Join();
暗さは特徴ですか?
私は何か間違ったことをしていますか?
OS:Microsoft windows vista(残念ながら) x64
言語:C# 3.0|4.0
.Net バージョン:3.5|4
編集:
Personel[] spersonel;
プロセス:
void proc()
{
spersonel = Personel.GetRows(GetThreadSafeDataConnection());
}
人事:
internal static Personel[] GetRows(System.Data.SqlClient.SqlConnection Connection)
{
int i = 0;
int c = SomeOtherGODClass.Val_int(SomeGODClass.ExecuteScalar("Select Count(*) from Personel", Connection).ToString());
Personel[] Rs = new Personel[c];
System.Data.SqlClient.SqlDataReader sdr = SomeGODClass.ExecuteReader("Select * from Personel", Connection);
while (sdr.Read()) Rs[i++] = new Personel(sdr);
sdr.Close();
if (Rs.Length > 1) mergeSort(ref Rs);
return Rs;
}