Thread: MFC Dialog :: Slider Control child notification messages?

  1. #1
    Programming is fun, mkay?
    Join Date
    Oct 2001
    Posts
    490

    Question MFC Dialog :: Slider Control child notification messages?

    Hello, everyone. I have an MP3 file player application that I have been working on for quite a while. It uses the FMOD library, and MFC. I have MS Visual C++ 6.0 on a Windows 98 machine.

    Anyhow, it is coming along really well. I have the option to select a new directory (SHBrowseForFolder) for the "playlist" of files. I implemented a slider a few days ago, which displays the status of the track's time as it plays, which is no problem. BTW, this is an MFC Dialog-Based Application.

    With the slider, I would like the user to be able to drag the slider to select a new position in the song. The problem is, I don't know how to know when the slider's position has changed. Can anyone please tell me how to know when the user drags the tracker on a slider control? If so, I would really appreciate the help.

    Thanks for the help,
    Matt U.
    Website(s): http://www16.brinkster.com/trifaze/

    E-mail: [email protected]

    ---------------------------------
    C++ Environment: MSVC++ 6.0; Dev-C++ 4.0/4.1
    DirectX Version: 9.0b
    DX SDK: DirectX 8.1 SDK

  2. #2
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,868
    look at

    OnNMCustomdraw or NM_CUSTOMDRAW

    then get the slider pos and process.
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

  3. #3
    Programming is fun, mkay?
    Join Date
    Oct 2001
    Posts
    490

    Talking Thanks for the reply ...

    Thanks for the reply. I figured it out myself. I just had to handle "OnHScroll" for a horizontal slider, and "OnVScroll" for a vertical slider. I just use the "TB_(Message)" messages for getting the new position.
    Website(s): http://www16.brinkster.com/trifaze/

    E-mail: [email protected]

    ---------------------------------
    C++ Environment: MSVC++ 6.0; Dev-C++ 4.0/4.1
    DirectX Version: 9.0b
    DX SDK: DirectX 8.1 SDK

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. MFC Bring up a dialog.
    By guitarist809 in forum Windows Programming
    Replies: 5
    Last Post: 08-06-2007, 01:31 AM
  2. Spy++ view messages posted/sent to a control, or from it?
    By hanhao in forum Windows Programming
    Replies: 2
    Last Post: 06-24-2007, 11:07 PM
  3. Tab Controls - API
    By -KEN- in forum Windows Programming
    Replies: 7
    Last Post: 06-02-2002, 09:44 AM
  4. Focusing a CEdit Object in a Dialog On Startup :: MFC
    By kuphryn in forum Windows Programming
    Replies: 4
    Last Post: 04-21-2002, 02:39 AM
  5. Dialog Window Initial Location :: MFC
    By kuphryn in forum C++ Programming
    Replies: 1
    Last Post: 04-06-2002, 10:34 AM