private void button5_Click(object sender, EventArgs e) { //ConfigFileHelper.ConfigPath = Directory.GetCurrentDirectory() + "\\SystemConfig.ini"; //string result = ConfigFileHelper.IniReadValue("Subject1", "Moudle1", ConfigFileHelper.ConfigPath); //initProblemToMoudle(); QuestionManager.FileCopy(@"D:\Projects\C#\DirvingTest\DirvingTest\bin\test\1522.swf", @"D:\Projects\C#\DirvingTest\DirvingTest\bin\test\1543.swf"); }
private void buttonSave_Click(object sender, EventArgs e) { if (null == FormBack) { return; } if (false == CheckQuestionInfo()) { return; } if (DialogResult.No == MessageBox.Show("确认要保存此题目信息吗?", "确认信息", MessageBoxButtons.YesNo)) { return; } BindUIToQuestion(); if (true == FormBack(m_question, true)) { if (!string.IsNullOrEmpty(_pathImage)) { string path = Directory.GetCurrentDirectory() + "\\Images\\" + m_question.Id.ToString() + Path.GetExtension(_pathImage); if (path != _pathImage) { QuestionManager.FileCopy(_pathImage, path); } } if (!string.IsNullOrEmpty(_pathFlash)) { string path = Directory.GetCurrentDirectory() + "\\Flash\\" + m_question.Id.ToString() + Path.GetExtension(_pathFlash); if (path != _pathFlash) { QuestionManager.FileCopy(_pathImage, path); } } MessageBox.Show("保存题目信息成功,题目id:" + m_question.Id.ToString() + ".", "提示信息", MessageBoxButtons.OK); } else { MessageBox.Show("保存题目信息失败,题目id:" + m_question.Id.ToString() + "请检查题目信息!", "提示信息", MessageBoxButtons.OK); } }