transxls.gms : Solve classical transportation problem in Excel, using vba API (opt and gdx)

Description

In this example GAMS runs only in the background. We use the vba version of the
GDX API to write a GDX file from data defined in the spreadsheet. With the
option object API we set several GAMS options from vba and solve the model
using the gams executable. At the end the solution is written into the workbook
using the GDX vba API again.


Category : GAMS Data Utilities library


Main file : transxls.gms   includes :  transxls.gms  transport.xlsm

$title  Transportation Problem
$onText

In this example GAMS runs only in the background. We use the vba version of the
GDX API to write a GDX file from data defined in the spreadsheet. With the
option object API we set several GAMS options from vba and solve the model
using the gams executable. At the end the solution is written into the workbook
using the GDX vba API again.

$offText

$callTool win32.msappavail Excel
$if errorlevel 1 $abort.noError "No Excel available"

$call "start transport.xlsm"