IOyesNo |
Top Previous Next |
If a "Yes and no question generates ""and delivers input back. This function generates from the handed over sign chain and the default for the positive answer (WORLDWIDE 1) and for the negative answer (WORLDWIDE 2) a question which is to be answered by one of these both possibilities. Besides, it is enough to give the first significant signs. If the input is not unequivocal or not one of both default, appears a suitable tip (WORLDWIDE 4) and the question is put once more. To permit an answer with the Digitalisiercursor, #L is understood as a no and #P as Yes. With suitable configuration the queries are formulated as a dialogue. Parametre root (PROOT) [IN] Act on the open data bank. promptly (const char *) [IN] This sign chain contain the real question which is indicated in the dialogue window and is to be answered with Yes or no or demolition. dflt (int) [IN] This value specifies the Defaultantwort. If the user answers only by pressure of the <RETURN >key so becomes this value zurückgeliefert. This value should be from the data area of the return values {0, 1}, however, can have also another value (e.g., 2), because he is not checked by the function. helpID (const char *) [IN] Name of the accompanying help subject in the Moskito's help if the subject does not stand in user.hlp ""is used as a syntax "Datei|Thema". Result (int) [OUT] 1 positive answer ""elective 0 negative answer ""elective Declaration #include "system.h"
int DLLENTRY IOyesNo ( PROOT root, const char * promptly, int dflt const char * helpID ); Remarks If with setEcho (), or „echo / of DIALOGUE“, to dialogue-based user interface is switched the queries appear message boxing. It can be also worked with Yes and No. The file MELDUNG.DAT contain among other things the following lines which can be adapted when required: --- WORLDWIDE 1 Yes --- WORLDWIDE 2 No --- WORLDWIDE 9 Yes --- WORLDWIDE 10 No --- WORLDWIDE 3 Demolition Example status = IOyesNo (root, "STRAESSLE compatibly?", 1, ZERO) Of the variables "status" becomes the Return value of the function IOyesNo assigned, she asks whether a certain function compatibly to the GRADIS of the company STRAESSLE should run off. If this question <>is answered only by pressure of the <RETURN >key, the function delivers the value "1" back what corresponds to the negative answer.
|