February 14th, 2003, 03:50 AM
im a newbie working on a windows console type program and was wondering how to go about making it run in full screen?
February 14th, 2003, 01:09 PM
Set your focus to the console and type Alt-Enter to go to full screen mode. Type alt-enter again to go back to windowed mode.
February 14th, 2003, 09:28 PM
I know that much I was hoping someone could help me out with programing it to run fullscreen when you run it.
February 15th, 2003, 01:41 PM
There is no offical way to do this (although there is probably an undocumented function or alt-enter could not work either)
You can make a shortcut to the program and setup "run fullscreen" there.
February 16th, 2003, 03:09 AM
I finally found a tutorial that showed an easy way to go bout it.
thought id paste it here for anyone else that may find use of it.
February 16th, 2003, 03:22 AM
"easy way" :D sorry iīm laughing....
Donīt forget to SetFocus() and SetForegroundWindow() before this, or you will send the key sequence to another running program if your program doesnīt have the focus or is backgrounded... But then - in WinXPīs default configuration, SetForegroundWindow() does not work anymore :rolleyes:
Last edited by M.Hirsch; February 16th, 2003 at 05:33 AM.
February 16th, 2003, 04:40 AM
I'm sure there are all kinds of ways to go about it. I'm not to excited with the idea of writing an app and then zip'n it up with a premade shortcut when i could just write the app to run fullscreen, and i definately wasn't gonna have a user run it hold alt and push enter everytime.
February 16th, 2003, 05:32 AM
Just to make this clear: i wasnīt laughing at you but on this code and the explanations that came with it. Itīs just wrong. Also we just recently had the discussion about why not to put functions in header files. :rolleyes:
To explain this code a little more: keybd_event() does NOT switch to fullscreen mode. It is simulating pressing keys. Here it is ALT+ENTER. In some cases this will switch your app to fullscreen. In some it just wonīt.
Eg. it will put it back in windowed mode if you call it twice or if the user did alredy start the program in fullscreen mode. But you canīt check if it is already running in fullscreen mode either. Also it would add a page break in your Word document, if Word was the application with the focus in the moment you call this code. IMHO itīs not a good approach. But:
Sorry i was wrong about the shortcut. I just checked, it cannot be done like this either. Seems like your solution is the only way although i still donīt like it :( Just make sure your app is the window with the focus.
February 16th, 2003, 05:40 AM