C/C++ WIN32 Console, Turn Cursor Off?

Started by
3 comments, last by Tonic151 20 years, 5 months ago
hi, i was wondering if there is anyway to turn the cursor off in my Win32 Console program.. using c/c++ Thanks Much!!
Advertisement
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);CONSOLE_CURSOR_INFO CCI;GetConsoleCursorInfo(hOut, &CCI);CCI.bVisible = false;SetConsoleCursorInfo(hOut, &CCI); 

EDIT: Forgot a line

-- Sorcerer --

[edited by - TheSorcerer on November 15, 2003 3:11:37 PM]
Ah this is interesting to me, I was going to ask something about the console. Last night I accidently discovered you could run it in full screen mode, by one of the buttons at the top, I wanted to know a bit more about it, so I looked on properties (right click - properties) and found a whole lot of ms-dos tabs/commands, you can do various things in there, (there is more), I found it would only go to full screen for that go, but the next time you started it, it would run in normal mode again. I wanted to find out more, the ms-dos name of the console is "conagent.exe" and that is in the windows>system directory, if you go to this and do the properties there you can change a whole lot of settings including getting the console to come up full screen every time, like a proper dos screen , you can also change it back as well if you want.
I would also be interested in any commands you can include in your program as well to do these things, so you could have it come up normal or full screen when you want rather thn one or the other?
quote:Original post by TheSorcerer
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);CONSOLE_CURSOR_INFO CCI;GetConsoleCursorInfo(hOut, &CCI);CCI.bVisible = false;SetConsoleCursorInfo(hOut, &CCI);  

EDIT: Forgot a line


thank you very much!
That code actually works!!! I''ve been trying to figure out how to turn the cursor off for a year now. But thanks to you my problems are finally solved!

This topic is closed to new replies.

Advertisement