Thread: How do you create two consoles with one program?

  1. #1
    Registered User
    Join Date
    Sep 2008
    Posts
    42

    How do you create two consoles with one program?

    Here's the situation. I would like to be able to have to window consoles running by one program. the program is a text adventure game. One window would contain all the info and actions going on. The second window would be an ascii map of your character moving.

    Problem is I have no idea where to start and how to do it. I know very little about HANDLEs. I found this page about Console Functions but I have no idea how to use it. I would need to know how to switch between windows back and forth to do actions properly.
    Console Functions (Windows)

    any help would be great.
    Last edited by edomingox; 11-15-2010 at 06:49 PM.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    AllocConsole .... "A process can be associated with only one console,"

    I think you need another plan, if you were planning on two consoles.

    You can create as many GUI windows as you like, and make them "look" like consoles.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  3. #3
    Registered User
    Join Date
    Sep 2008
    Posts
    42
    That may be the same thing I can use. Is there an easy way to do such a thing? I've never done something like that before. I wouldn't know where to start.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 5
    Last Post: 11-27-2010, 12:42 PM
  2. Button handler
    By Nephiroth in forum Windows Programming
    Replies: 8
    Last Post: 03-12-2006, 06:23 AM
  3. How to create a file association program?
    By eShain in forum Windows Programming
    Replies: 1
    Last Post: 03-06-2006, 12:15 PM
  4. Trying to create a payroll calculation program
    By nadeni0119 in forum C++ Programming
    Replies: 1
    Last Post: 04-01-2003, 04:14 PM
  5. program won't create status bar
    By Unregistered in forum Windows Programming
    Replies: 7
    Last Post: 08-30-2001, 04:00 PM