Thread: Help with prog

  1. #1
    Banned
    Join Date
    May 2004
    Posts
    55

    Help with prog

    Hello, I'm going to make a program that first reads from program.ini and then writes what stands inside (when a key is pressed), like, you press f12 and it writes your password directly, but I've got stuck here:
    Code:
        switch (message)
        {
            case WM_DESTROY:
                PostQuitMessage (0);
                break;
            case WM_CLOSE:
                DestroyWindow(hwnd);
                break;
            case WM_KEYDOWN:
                switch (wParam)
                {
                    case VK_F12:
                    // The code to write whats inside program.ini
                }
            default:
                return DefWindowProc (hwnd, message, wParam, lParam);
        }
    grateful for answer
    Last edited by Noxir; 08-16-2004 at 10:18 AM.

  2. #2
    Software Developer jverkoey's Avatar
    Join Date
    Feb 2003
    Location
    New York
    Posts
    1,905
    I'm a bit confused as to what exactly you're stuck on....what exactly do you need help with?

  3. #3
    Banned
    Join Date
    May 2004
    Posts
    55
    Ok, I'm making a program that does this:

    Doubleclick: Starts the program.
    Press F12: Type the text inside file.ini, so you press F12 and it types the password inside file.ini (that the user have written) so you dont need to type your password yourself, you understand now? I've seen one of those programs made in C but I need to know the code in C++, Really grateful for answer
    Thnks!
    Last edited by Noxir; 08-16-2004 at 10:20 AM.

  4. #4
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    Really grateful for question
    You're telling us what your program is supposed to do, but you're not telling is what it isn't doing. Tell us the problem. Until you start stating this, and also reading the forum rules and putting helpful subject lines, no one's going to be bothered trying to figure out your problem for you. You also need to be clearer in what you're saying. Typing something in a file doesn't not happen. Are you writing the password to the file? Are you taking the password that's in the file and writing it to the screen? It sounds as though all you need is some basic file i/o.
    Last edited by sean; 08-16-2004 at 10:32 AM.

  5. #5
    Banned
    Join Date
    May 2004
    Posts
    55
    argl.............................................. .....
    Is it SO hard to understand?
    I press f12 on a game, there it stands "Password:", and have my program open.
    My program types my password so I don't need to type it myself
    And:
    This forum is for questions, and MY question is:
    Is it possible? and what is the code then? thnq, and the thing it isnt doing is typing the password when pressing F12,
    And yes I know basic I/O but this isn't the same thing.

    Still really grateful for answer
    Last edited by Noxir; 08-16-2004 at 11:19 AM.

  6. #6
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    This question has been asked and answered(probably not to Noxir's satisfaction) in the C++ forum. (Can we merge threads?).

    Noxir, please consider not posting your questions in two different forums.

    >> Is it SO hard to understand? <<

    Yes, you have told us what you want your program to do but have not indicated which part you are having problems with. There is several questions you could ask:

    - How do I intercept the F12 key in another application (this one is easy: you don't)?
    - How do I read text from an .ini file?
    - How do I ask a question on cboard?
    - How do I find which window to type the text in?
    - How do I choose which forum to post on?
    - How do I programmatically type text in another application?

    If you don't specify your actual question rather than a vague description of your program, we may waste our time answering a question that you don't need help with, as it seems we have done in the C++ forum version of this thread.
    Last edited by anonytmouse; 08-16-2004 at 11:45 AM.

  7. #7
    Banned
    Join Date
    May 2004
    Posts
    55
    The program is not ment to type a text in a specific program, it will just type the text in the program that is active.
    If you still don't know what i'm talkin' about then download this:

    http://www.tech-x.de/daten/TibiaPW.zip
    Last edited by Noxir; 08-17-2004 at 09:49 AM.

  8. #8
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    Look up RegisterHotKey(), SendInput(), GetPrivateProfileString(), CryptProtectData() and keybd_event().

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Assembly amature question: prog errors
    By geek@02 in forum Tech Board
    Replies: 1
    Last Post: 10-03-2008, 01:35 PM
  2. Getting input from another prog?
    By Badman3k in forum C Programming
    Replies: 4
    Last Post: 11-11-2004, 02:58 AM
  3. an option at the end of this prog to ask if I want to run again
    By bandito9111 in forum C++ Programming
    Replies: 2
    Last Post: 03-31-2003, 02:30 PM
  4. Try my prog...
    By Commander in forum A Brief History of Cprogramming.com
    Replies: 0
    Last Post: 05-09-2002, 07:43 AM
  5. password prog
    By ihsir in forum A Brief History of Cprogramming.com
    Replies: 10
    Last Post: 01-06-2002, 06:39 AM