Displays the specified character on the screen at the virtual cursor's current position.
Restriction: This function is supported for native COBOL only.


#include "cobscreen.h"

void cobaddch (cobchtype ch);


ch The required character and any attributes.


The specified character and attribute ch are displayed on the screen at the current position of the virtual cursor.

A character of \n (new line) is a valid character, and moves the virtual cursor to the beginning of the next line. No other control characters are valid; their use causes undefined results.

Equivalent COBOL Syntax:

None. However, this routine is similar to the COBOL syntax:

call "CBL_WRITE_SCR_CHATTRS" using ... 


To display the character "X" in reverse-video, use:

cobaddch('X' | A_REVERSE)