Esempio n. 1
0
        private void buttonRefresh_Click(object sender, EventArgs e)
        {
            this.screenShotPath = ScreenData.GetScreemShotPath();
            File.Delete(this.screenShotPath);
            TaskInfo t = TaskInfo.Create(TaskType.ScreenShot, this.screenShotPath);

            t.ResultHandler = new TaskInfo.EventResultHandler(getScreenShotResult);
            taskThread.SendTask(t);
        }
        /// <summary>
        /// 载入屏幕截图
        /// </summary>
        private void loadScreenShot()
        {
            this.screenShotPath = ScreenData.GetScreemShotPath();
            try
            {
                File.Delete(this.screenShotPath);
            }
            catch
            {
            }
            TaskInfo t = TaskInfo.Create(TaskType.ScreenShot, this.screenShotPath);

            t.ResultHandler = new TaskInfo.EventResultHandler(getScreenShotResult);
            taskThread.SendTask(t);
        }