Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to get the "Enter" Key down notification from CListCtrl

How to get the "Enter" Key down notification from CListCtrl

Scheduled Pinned Locked Moved C / C++ / MFC
tutorialquestion
5 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    Nitheesh George
    wrote on last edited by
    #1

    Hi, I want to get the "Enter" Key down notification from a ClistCtrl. I have handled the LVN_KEYDOWN but the parent window is not notified when "Enter" Key is pressed and the Parent window is notifies when all other keys are down. How can i get notified when "Enter" key is pressed. I tried using NM_ENTER but nothing happened. thanks Nitheesh

    Jose Jo Martin http://www.simpletools.co.in

    C C 2 Replies Last reply
    0
    • N Nitheesh George

      Hi, I want to get the "Enter" Key down notification from a ClistCtrl. I have handled the LVN_KEYDOWN but the parent window is not notified when "Enter" Key is pressed and the Parent window is notifies when all other keys are down. How can i get notified when "Enter" key is pressed. I tried using NM_ENTER but nothing happened. thanks Nitheesh

      Jose Jo Martin http://www.simpletools.co.in

      C Offline
      C Offline
      Chandrasekharan P
      wrote on last edited by
      #2

      why don't you use spy++ tool to get the notification

      N 1 Reply Last reply
      0
      • C Chandrasekharan P

        why don't you use spy++ tool to get the notification

        N Offline
        N Offline
        Nitheesh George
        wrote on last edited by
        #3

        Hi , I want to handle the "Enter" key event on the parent window. Do u have an idea.

        Jose Jo Martin http://www.simpletools.co.in

        1 Reply Last reply
        0
        • N Nitheesh George

          Hi, I want to get the "Enter" Key down notification from a ClistCtrl. I have handled the LVN_KEYDOWN but the parent window is not notified when "Enter" Key is pressed and the Parent window is notifies when all other keys are down. How can i get notified when "Enter" key is pressed. I tried using NM_ENTER but nothing happened. thanks Nitheesh

          Jose Jo Martin http://www.simpletools.co.in

          C Offline
          C Offline
          Code o mat
          wrote on last edited by
          #4

          If your list is on a dialog box you can use this trick: In the OnOK handler of the dialog check if the focus is on your list control or not, if it is, then the user pressed the ENTER key in your list. Don't know if this aproach has any drawbacks or glitches in it.

          > The problem with computers is that they do what you tell them to do and not what you want them to do. < > Life: great graphics, but the gameplay sux. <

          N 1 Reply Last reply
          0
          • C Code o mat

            If your list is on a dialog box you can use this trick: In the OnOK handler of the dialog check if the focus is on your list control or not, if it is, then the user pressed the ENTER key in your list. Don't know if this aproach has any drawbacks or glitches in it.

            > The problem with computers is that they do what you tell them to do and not what you want them to do. < > Life: great graphics, but the gameplay sux. <

            N Offline
            N Offline
            Nitheesh George
            wrote on last edited by
            #5

            Hi, thanks for your reply. Unfortunately my Listview is in CFormView. So this trick is not going to work for me. Any other method other than subclassing the ClistCtrl?. thanks Nitheesh

            Jose Jo Martin http://www.simpletools.co.in

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups