private void LoadDllFile(string dllfile) { label1.Visible = false; label2.Visible = false; button_start.Enabled = false; int ret = dd.Load(dllfile); if (ret != 1) { MessageBox.Show("Load Error"); return; } ret = dd.btn(0); //DD Initialize if (ret != 1) { MessageBox.Show("Initialize Error"); return; } button_start.Enabled = true; label1.Visible = true; label2.Visible = true; textBox1.Text = dllfile; return; }
private void LoadDllFile(string dllfile) { label1.Visible = false; label2.Visible = false; button_start.Enabled = false; System.IO.FileInfo fi = new System.IO.FileInfo(dllfile); if (!fi.Exists) { MessageBox.Show("文件不存在"); return; } int ret = dd.Load(dllfile); if (ret == -2) { MessageBox.Show("装载库时发生错误"); return; } if (ret == -1) { MessageBox.Show("取函数地址时发生错误"); return; } if (ret == 0) { MessageBox.Show("非增强模块"); } dd.btn(0); button_start.Enabled = true; label1.Visible = true; label2.Visible = true; textBox1.Text = dllfile; return; }