|
Parameters in a spreadsheet |
Top Previous Next |
|
Command line parameters can be placed in a range of a spreadsheet then read. This is indicated by including the use of the Index command line parameter
Index = ExcelRange Example: Suppose I wish to integrate all the features of the gdxxrwread.gms example into an index area of a spreadsheet. I can do this using the myindex sheet of the gdxxrwss.xls spreadsheet and the GAMS code in the example gdxxrwread2.gms as follows
$call gdxxrw gdxxrwss.xls o=gdxall.gdx index=myindex!a1
where the myindex sheet looks like
Notes:
Another Example: The GAMS program gdxxrwwrite2.gms employs the use of an index area in a workbook in writing. Namely in the writeindex sheet of gdxxrwss.xls I have
which is addressed by the command $call "gdxxrw i=gdxse.gdx o=gdxxrwss.xls index=writeindex!a2"
and shows how the merge and clear commands are entered. |