2using System.Collections.Generic;
3using System.ComponentModel;
8using System.Windows.Forms;
9using System.Runtime.InteropServices;
10using System.Diagnostics;
11using System.Threading.Tasks;
25 public partial class Form1 : Form
30 InitializeComponent();
31 this.ControlBox =
false;
34 private void RunGams()
36 MethodInvoker action = delegate
38 bu_run.Enabled =
false;
39 bu_close.Enabled =
false;
40 bu_cancel.Enabled =
true;
43 this.BeginInvoke(action);
51 opt.AllModelTypes =
"soplex";
56 currentJob.
Run(opt, tbw);
62 richTextBox1.AppendText(e.Message);
68 bu_run.Enabled =
true;
69 bu_close.Enabled =
true;
70 bu_cancel.Enabled =
false;
72 this.BeginInvoke(action);
75 private void bu_run_Click(
object sender, EventArgs e)
77 Task.Factory.StartNew(() => RunGams());
80 private void bu_cancel_Click(
object sender, EventArgs e)
85 private void bu_close_Click(
object sender, EventArgs e)
void Run(GAMSOptions gamsOptions=null, GAMSCheckpoint checkpoint=null, TextWriter output=null, Boolean createOutDB=true)
void GamsLib(string model)
GAMSJob AddJobFromFile(string fileName, GAMSCheckpoint checkpoint=null, string jobName=null)
GAMSOptions AddOptions(GAMSOptions optFrom=null)