branchobj.getlasterror
branchobj.getlasterror |
Purpose
Returns the last error encountered during a call to the given branch object.
Synopsis
(id,msg) = branchobj.getlasterror()
Arguments
id
|
Error code.
|
msg
|
A string with the last error message relating to the branching object will be returned.
|
Example
The following shows how this function might be used in error checking:
obranch = xpress.branchobj() try: obranch.setpreferredbranch(3) except: (i,m) = obranch.getlasterror() print("ERROR when setting preferred branch:", m)