GDXXRWExample15.gms : Writing to Spreadsheet using a Filter

Description

The following example creates a small GDX file which is used to write
the symbol A to a spreadsheet with the filter enabled.

This model is referenced in "Writing Spreadsheet using a Filter" from
the GDXXRW Documentation.


Category : GAMS Data Utilities library


Main file : GDXXRWExample15.gms   includes :  GDXXRWExample15.gms

$title Writing to Spreadsheet using a Filter (GDXXRWExample15,SEQ=076)

$onText
The following example creates a small GDX file which is used to write
the symbol A to a spreadsheet with the filter enabled.

This model is referenced in "Writing Spreadsheet using a Filter" from
the GDXXRW Documentation.
$offText

$if %system.filesys% == UNIX $abort.noError 'This model cannot run on a non-Windows platform';
$libInclude win32 -c msappavail Excel
$ifE errorLevel<>0 $abort.noError 'Microsoft Excel is not available!';

Set
   i / i1*i2 /
   j / j1*j2 /
   k / k1*k2 /;

Parameter A(i,j,k);
A(i,j,k) = uniform(0,1);

execute_unload 'test.gdx', A;
execute 'gdxxrw test.gdx filter=2 par=A rDim=1 cDim=2 rng=sheet1!A1 trace=0';