Error messages

Information about Programming in the MOHID Framework
MOHID Advanced user
Posts: 117
Joined: Thu Jan 01, 1970 00:00
Location: Lisbon

Error messages

Postby » Fri Jul 15, 2005 10:27

Dear all,
just a tip. When you are programming error messages please do not numbering them like this :

stop 'suborutine - module - ERR01'

more code

stop 'suborutine - module - ERR02'

It's best numbering the errors like this:

stop 'suborutine - module - ERR10'

more code

stop 'suborutine - module - ERR20'

This way when some one want to introduce new error messages between to old ones do not have to renumerate the all subroutine error messages.

Posts: 151
Joined: Thu Jan 01, 1970 00:00
Location: Technical University of Lisbon

Error Messages

Postby » Mon Jul 18, 2005 22:03

Dear All,

really correct the code should look like:

if (STAT_CALL /= SUCCESS_) stop 'ConstructModel - ModuleModel - ERR10'

This means that the message after the stop statement is composed by: <Name of the subroutine> - <Name of the Module> - <Error Code>


Return to “MOHID Programming”

Who is online

Users browsing this forum: No registered users and 2 guests