Gotoxy in Dev c++
Using gotoxy funxtion is quiet difficult in devc++ because there is no such header file present in dev c++ to use gotoxy function. What we have to all do is that we have to create the function for positioning cursor in devc++
I am showing you here a simple example for using gotoxy function :
I am showing you here a simple example for using gotoxy function :
#include<stdio.h>#include<conio.h>#include<windows.h>void gotoxy(short x, short y); //here we declare the gotoxy function//main(){gotoxy(30,16); //now where we want to call gotoxy function //printf("Hi i am,here");return 0;}void gotoxy(short x, short y) //definition of gotoxy function//{COORD pos ={x,y};SetConsoleCursorPosition(GetStdHandle(STD_OUTPUT_HANDLE), pos);}
Note that gotoxy is function name here i.e. you are able to change that it may be anything except keywords
thanks. it does work!
ReplyDeleteThanx a lot, it was helpful
ReplyDeletethank u it's working
ReplyDeleteThank you so much , it works!
ReplyDeleteThank you so much,i'm really happy..
ReplyDeleteIt doesn't work for Android? I hope have on androAn user, I don't have a laptop or PC just Android:-(
ReplyDelete