GiD_Event_SelectGIDBatFile: must be used to switch the default batch file for special cases.

This procedure must return as a value the alternative pathname of the batch file. For example it is used as a trick to select a different analysis from a list of batch calculation files.

proc GiD_Event_SelectGIDBatFile { dir basename } {

...body...

set value ...

return $value

}

GiD_Event_BeforeRunCalculation: will be called before running the analysis. It receives several arguments:

  • batfilename: the name of the batch file to be run
  • basename: the short name model;
  • dir: the full path to the model directory;
  • problemtypedir: the full path to the Problem Types directory;
  • gidexe: the full path to gid;
  • args: an optional list with other arguments.

If it returns -cancel- then the calculation is not started.

proc GiD_Event_BeforeRunCalculation { batfilename basename dir problemtypedir gidexe args } {

...body...

set value ...

return $value

}

GiD_Event_AfterRunCalculation: will be called just after the analysis finishes.

If it returns -cancel-as a value then the window that inform about the finished process will not be opened.

It receives as arguments:

  • basename: the short name model;
  • dir: the full path to the model directory;
  • problemtypedir: the full path to the Problem Types directory;
  • where: must be local or remote (remote if it was run in a server machine, using ProcServer);
  • error: returns 1 if an calculation error was detected;
  • errorfilename: an error filename with some error explanation, or nothing if everything was ok.

proc GiD_Event_AfterRunCalculation { basename dir problemtypedir where error errorfilename } {

...body...

set value ...

return $value

}