<a href="http://gan.doubleclick.net/gan_click?lid=41000000035692252&pubid=21000000000397534">wherex</a> gives current horizontal cursor position
wherey gives current vertical cursor position
Declaration:
int wherex(void);
int wherey(void);
Remarks:
wherex returns the x-coordinate of the current cursor position (within the
current text window).
wherey returns the y-coordinate of the current cursor position (within the
current text window).
Return Value:
wherex returns an integer in the range 1 to 80.
wherey returns an integer in the range 1 to 25,
1 to 43, or 1 to 50.
Example:
#include <conio.h>
int main(void)
{
clrscr();
gotoxy(10,10);
cprintf("Current location is X: %d Y: %d\r\n", wherex(), wherey());
getch();
return 0;
}
0 comments:
Post a Comment