msg#
- Mapdl.msg(lab='', val1='', val2='', val3='', val4='', val5='', val6='', val7='', val8='', **kwargs)#
Writes an output message via the ANSYS message subroutine.
APDL Command:
*MSG
- Parameters:
- lab
Label for output and termination control:
Writes the message with no heading (default). - Writes the message with a “NOTE” heading.
Writes the message with a “WARNING” heading. Also writes the message to the errors file, Jobname.ERR. - Writes the message with a “ERROR” heading and causes run termination (if batch) at earliest “clean exit” point. Also writes the message to the errors file, Jobname.ERR.
Writes the message with a “FATAL ERROR” heading and causes run termination immediately. Also writes the message to the errors file, Jobname.ERR. - Writes the message with a “NOTE” heading and displays it in the message dialog box. This option is most useful in GUI mode.
- val1, val2, val3, … , val8
Numeric or alphanumeric character values to be included in message. Values may be the results of parameter evaluations. All numeric values are assumed to be double precision. The FORTRAN nearest integer (NINT) function is used to form integers for the %I specifier.
Notes
Allows writing an output message via the ANSYS message subroutine. Also allows run termination control. This command is used only when contained in a prepared file read into the ANSYS program (i.e.,
*USE,/INPUT
, etc.). A message format must immediately follow the*MSG
command (on a separate line, without parentheses, as described below).The message format may be up to 80 characters long, consisting of text strings and predefined “data descriptors” between the strings where numeric or alphanumeric character data are to be inserted. The normal descriptors are %I for integer data, %G for double precision data, %C for alphanumeric character data, and %/ for a line break. The corresponding FORTRAN data descriptors are I9, 1PG16.9 and A8, respectively. Each descriptor must be preceded by a blank. There must be one data descriptor for each specified value (8 maximum) in the order of the specified values.
Enhanced descriptions may also be used:
Do not begin
*MSG
format lines with*IF
,*ELSE
,*ELSEIF
, or*ENDIF
. If the last nonblank character of the message format is an ampersand (&), a second line will also be read as a continuation of the format. Up to nine continuations (ten total lines) may be read. If normal descriptions are used, then consecutive blanks are condensed into one blank upon output, and a period is appended. Up to ten lines of output of 72 characters each may be produced (using the %/ descriptor). Two examples follow.Here is an example of the
*MSG
command and a format to print a message with two integer values and one real value:The output line is:
Here is an example illustrating multiline displays in GUI message windows:
Note:: : The /UIS,MSGPOP command controls which messages are displayed in the message dialog box when the GUI is active. All messages produced by the
*MSG
command are subject to the /UIS specification, with one exception, If Lab = UI, the message will be displayed in the dialog box regardless of the /UIS specification.This command is valid in any processor.