Intermec Janus 2020 Reference Manual - Im_Iswarn
im_iswarn
3-72
im_iswarn
Purpose:
This macro determines if the return status code from another PSK function
is a warning.
Syntax:
With System, Text_IO, Intrmecd_IO, Intrmecp_IO;
Use System, Text_IO, Intrmecd_IO, Intrmecp_IO;
function im_iswarn(
status :System.Word
) return Boolean;
IN Parameters:
The status parameter is any PSK function that returns a status code.
OUT Parameters:
None.
Return Value:
0
Indicates success or an error (either fatal or nonfatal)
nonzero
Indicates a warning
See Also:
“Status Code Macros” in Chapter 2, “Working With Ada,”
im_iserror, im_isgood, im_issuccess
Example
With System, Text_IO, Intrmecd_IO, Intrmecp_IO;
Use System, Text_IO, Intrmecd_IO, Intrmecp_IO;
procedure ex_iswarn is
status : System.Word;
begin
status := im_sound(IM_LOW_PITCH, IM_BEEP_DURATION, IM_NORMAL_VOLUME);
if im_iswarn(status) then
Put_Line('Beep warning!');
else
Put_Line('Beep success or error!');
end if;
New_Line;
end ex_iswarn;