Thread: HWND problem

  1. #16
    Reverse Engineer maxorator's Avatar
    Join Date
    Aug 2005
    I went over to Win32 API when I had messed with console for about 5 days.
    I really don't understand, why people mess with console anyway...

  2. #17
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    many applications do not need a gui. Most of the valuable stuff on unix/linux is command line utilities/servers. Additionally, console is a pretty good place to stay while learning C++ because you don't get bogged down in learning something as complex as the Win32 API while you should be concentrating on the language.
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  3. #18
    Reverse Engineer maxorator's Avatar
    Join Date
    Aug 2005
    Win32 API is simple... extremely simple...

  4. #19
    Registered User
    Join Date
    May 2003
    On the original question -- you can get a handle to the console window using the API function GetConsoleWindow(). However, you can't (easily) receive window messages so it's of only limited use if you want to learn event-driven programming.
    You ever try a pink golf ball, Wally? Why, the wind shear on a pink ball alone can take the head clean off a 90 pound midget at 300 yards.

  5. #20
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    You can get resize events with ReadConsoleInput (the mode, set with SetConsoleMode, has to be correct). Some other interesting events can be obtained with SetConsoleCtrlHandler.

    However, the console programs should typically be limited to programs that take a command line and output text. Anything more complicated typically requires a custom GUI.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Avoiding Global variables
    By csonx_p in forum Windows Programming
    Replies: 32
    Last Post: 05-19-2008, 12:17 AM
  2. 3 windows, cpu 100%
    By phil in forum Windows Programming
    Replies: 3
    Last Post: 08-01-2005, 08:45 AM
  3. edit box affecting displaying of text?
    By algi in forum Windows Programming
    Replies: 4
    Last Post: 05-04-2005, 03:28 PM
  4. Really Need Help With My Opengl Camera!!!!
    By psychopath in forum Game Programming
    Replies: 13
    Last Post: 05-28-2004, 03:05 PM
  5. button 'message'
    By psychopath in forum Windows Programming
    Replies: 12
    Last Post: 04-18-2004, 09:57 AM
Website Security Test