thread 썸네일형 리스트형 c# 크로스 스레드(CheckForIllegalCrossThreadCalls) // This event handler creates a thread that calls a // Windows Forms control in an unsafe way. private void setTextUnsafeBtn_Click( object sender, EventArgs e) { this.demoThread = new Thread(new ThreadStart(this.ThreadProcUnsafe)); this.demoThread.Start(); } // This method is executed on the worker thread and makes // an unsafe call on the TextBox control. private void ThreadProcUnsafe() { this... 더보기 (C#) FiFo Semaphore 예전에 설계시간에 FiFo 세마포어를 사용할일이 있어서 만든겁니다. C#에서는 기본적으로 세마포어를 제공해주는데 세마포어에서 Release 해줄때 순차적으로 릴리즈 해주는게 아니라 랜덤으로 나와서 몇일 고생하며 만든 기억 이 나네요~ 잘 쓰시길 바래요 Release 함수는 프로젝트를 열어봐야해서 다음에 시간되면 포스팅 하겠습니다 private void enterWait(object num) { Thread tempThread = null; int number = (int)num; if (enternumber > 0) { enternumber--; return; } else { tempThread = Thread.CurrentThread; this.Q.Enqueue(tempThread); lock (tem.. 더보기 이전 1 다음