PDA

View Full Version : back a line



madmardigan53
08-04-2003, 04:26 PM
I know that (char)8 is backspace, 13 is carriage return, and 10 is line break, but what is the ASCII equivalent of going up a line?

madmardigan53
08-04-2003, 04:40 PM
#include<func.h>/*contains iostream & some of my own functions*/
int main(int argc,char*argv[])
{
cout<<"yo\n"<<'\v'<<'h';
getch();
return 0;
}
/* Output:
yo
(mars)h
Desired Output:
ho*/

madmardigan53
08-04-2003, 04:59 PM
'\v' neither went up nor down one line.
I wish to output something, then a line break, then go back to the previous line to edit it.

madmardigan53
08-04-2003, 05:07 PM
#include<func.h>/*already includes conio.h*/
int main(int argc,char*argv[])
{
cout<<"laj\n";
gotoxy(1,1);
cout<<"f";
getch();
return 0;
}
/*Desired Output:
faj
Result:
[Linker error] undefined reference to `gotoxy'*/

madmardigan53
08-04-2003, 05:14 PM
dev-cpp
this also occurred when i attempted to change textcolor

madmardigan53
08-04-2003, 05:19 PM
#include<func.h>
int main(int argc,char*argv[])
{
cout<<"laj\n";
gotoxy(1,1);
cout<<"f";
getch();
return 0;
}
/*Output:
faj*/

also works for textcolor-thx