wherex
raw OCR
Gives horizontal cursor position within window.
Defined in header <conio.h>
Syntax
#include <conio.h>
int wherex(void);
Portability
| DOS | UNIX | Windows | ANSI C | C++ only |
|---|---|---|---|---|
| ■ |
Remarks
wherex returns the x-coordinate of the current cursor position (within the current text window).
Return value
wherex returns an integer in the range 1 to 80.
See also
Example
#include <conio.h>
int main(void)
clrscrO;
gotoxy(10,10),•
cprintf("Current location is X: %d Y; %d\r\n", wherexO, wherey (
getchO;
return 0;
Differences from modern implementations
Nothing recorded yet.
Modern references
These are search links, not yet checked by hand.
Stable link: /3.1/conio.h/wherex/
· short form /3.1/wherex/