我想要得到的形式,而不是在屏幕上的光標點,我明白我需要使用:光標點
Point ptCursor = Cursor.Position;
ptCursor = PointToClient(ptCursor);
的問題是,我在工作的方法使用該不同的線程,它給我這個錯誤信息:
Cross-thread operation not valid: Control 'Form1' accessed from a thread other than the thread it was created on.
爲什麼我得到這個錯誤消息? 我可以在線程上運行的方法中使用這些行嗎? 如何在幾秒鐘內調用一個方法在表單線程上運行?