SLPgetname
PurposeGet the name of an SLP item corresponding to a given indexSynopsisfunction SLPgetname(Type:integer, Index:integer) : string
Arguments
Type The type of item required. The full list is in the XSLP Function Reference manual; the following are those most commonly used:
- 1
- Row names
- 2
- Column names
- xslp_internalfuncnames
- Internal (pre-defined) function names
- xslp_userfuncnames
- User function names
- xslp_xvnames
- XV names
Index The index number of the item requiredReturn valueThe name of the indexed item in the problem of the appropriate type. An empty value means that the requested item was not found.ExampleThe following code fragment writes the names of the row, column, internal function and user function with index 2:i := 2 writeln("Row ",i, " is ", SLPgetname(1,i)) writeln("Column ",i, " is ", SLPgetname(2,i)) writeln("Internal function ",i, " is ", SLPgetname(xslp_internalfuncnames,i)) writeln("User function ",i, " is ", SLPgetname(xslp_userfuncnames,i))Further informationThis function is used principally to find the name in the problem of an item referenced by number. It is only useful where the problem is generated using meaningful names (set xslp_loadnames to true). Items are referenced by number particularly when they are passed as data to SLP callbacks.Related topics
If you have any comments or suggestions about these pages, please send mail to docs@dashoptimization.com.