System.Collections.Generic;
3usingSystem.ComponentModel;
8usingSystem.Windows.Forms;
9usingSystem.Runtime.InteropServices;
10usingSystem.Diagnostics;
11usingSystem.Threading.Tasks;
25 public partial class Form1: Form
30InitializeComponent();
31this.ControlBox =
false;
34 private voidRunGams()
36MethodInvoker action = delegate
38bu_run.Enabled =
false;
39bu_close.Enabled =
false;
40bu_cancel.Enabled =
true;
43this.BeginInvoke(action);
51opt.AllModelTypes =
"soplex";
56currentJob.
Run(opt, tbw);
62richTextBox1.AppendText(e.Message);
68bu_run.Enabled =
true;
69bu_close.Enabled =
true;
70bu_cancel.Enabled =
false;
72this.BeginInvoke(action);
75 private voidbu_run_Click(
objectsender, EventArgs e)
77Task.Factory.StartNew(() => RunGams());
80 private voidbu_cancel_Click(
objectsender, EventArgs e)
85 private voidbu_close_Click(
objectsender, 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)
This small example demonstrates how to run a GAMS model in a graphical user interface....
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4