inpm_xnp()

Purpose

Input function for fields without prompt

Syntax

int inpm_cnp(char *data)
int inpm_dnp(datetype *data)
int inpm_hnp(short *data)
int inpm_inp(int *data)
int inpm_lnp(long *data)
int inpm_nnp(double *data)
int inpm_snp(char *data)
int inpm_tnp(timetype *data)
int inpm_unp(char *data)

inpm_inp may be defined as a macro on some platforms.

Parameters

data Address of variable containing data to display and input

Description

The inpm_xnp() functions are the same as the inpm_x() functions except that they do not respond to the prompt facility. Pressing <Ctrl+P> has no effect when the global variable scrn_flags includes the value PROMPT_AVAILABLE.

In a screen of data entry where you wish some fields to respond to <Ctrl+P> but not others, you can use the inpm_xnp() functions to disable <Ctrl+P> for those fields that do not support it. By doing this, you do not have to keep changing the global variable scrn_flags.

These functions are implemented by calls to the general inpm() function using scrn_flags &~PROMPT_AVAILABLE as the flags parameter (or scrnd_flags in the case of date input).

Refer to the documentation of inpm_x() for further information on these functions.

Return values

Returns a non zero value (usually the value of the global variable abort_code) if the program should break (not validate the field), or zero if the data was entered normally and should be validated.