精華區beta Programming 關於我們 聯絡資訊
豆豆看世界 (LGW.bbs@cis.nctu.edu.tw) 提到: : 我有一個程式,其中有個function必須跑很久, : 而且跑的時候必須一直去update一個圖形, : 實驗的結果發現,那個圖形根本就不會update, : 一定要等到該function run完後,圖形結果才會跑出來, : 因此才想用兩個form,一個run, 一個show圖 : 請教一下, 兩個form不同thread,並有各自的message queue行得通嗎? Usually, one thread to do GUI, the other threads do your long time jobs. In your case, you must only one thread , you can improve by calling Application->ProcessMessages() in your function's loop. -- ================================================= 游順益: 天蠍座 E-mail daniel@info4.csie.nctu.edu.tw ------------------------------------------------- 羔羊無己,獅子無懼 =================================================