A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://www.gams.com/latest/docs/apis/examples_dotnet/InterruptGui_2Form1_8cs_source.html below:

InterruptGui/Form1.cs Source File

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)

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