CPXchgname


Description

The routine CPXchgname() changes the name of a constraint or the name of a variable in a CPLEX problem object. If this routine is performed on a problem object with no row or column names, default names are created before the change is made.

Return Value

The routine returns a zero on success, and a nonzero if an error occurs.

Synopsis

  int CPXchgname (CPXCENVptr env,
                  CPXLPptr lp,
                  int key,
                  int ij,
                  const char *newname_str);

Arguments

CPXCENVptr env

The pointer to the CPLEX environment as returned by CPXopenCPLEX().

CPXLPptr lp

A pointer to a CPLEX problem object as returned by CPXcreateprob().

int key

A character to indicate whether a row name or a column name should be changed:

key = 'r'  
change row name 
key = 'c
change column name 

int ij

An integer that indicates the numerical index of the column or row for which the name is to be changed.

const char *newname_str

A pointer to a character string containing the new name.

Example

  status = CPXchgname (env, lp, 'c', 10, "name10");

See Also

CPXdelnames()

Previous Page: CPXchgctype Return to Top Next Page: CPXchgobj