I just wrote the code for tower of hanoi in c and I wanted to show the solution in graphical mode using characters.
I want to use windows.h and SetConsoleCursorPosition
function to move cursor in console.
Could you help me by telling me have does this function works and how to use it?Please give some examples.
Here's an example of how to call the
SetConsoleCursorPosition
function, taken from cplusplus:You can also find out how to use Win32 functions by checking the SDK documentation. Googling for the name of the function will usually turn up the appropriate doc page as the first hit.
For
SetConsoleCursorPosition
, the page is here, and forGetStdHandle
, the page is here.