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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. Searching database for every keyboard press

Searching database for every keyboard press

Scheduled Pinned Locked Moved C#
helpdatabasealgorithmstutorialquestion
11 Posts 7 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.
  • G Offline
    G Offline
    gamer1127
    wrote on last edited by
    #1

    Hello to all. I'm having a little problem with one of the features that I want to have in my program. I want my program to search the names of the guest for every key press. For example, if I press H on the keyboard, all of the last names that starts with H should appear. I tried to use both KeyDown and KeyPress Events but either of them doesn't seem to work. Can anyone help me?

    A M P L 4 Replies Last reply
    0
    • G gamer1127

      Hello to all. I'm having a little problem with one of the features that I want to have in my program. I want my program to search the names of the guest for every key press. For example, if I press H on the keyboard, all of the last names that starts with H should appear. I tried to use both KeyDown and KeyPress Events but either of them doesn't seem to work. Can anyone help me?

      A Offline
      A Offline
      Abhinav S
      wrote on last edited by
      #2

      Post some code here and someone might be able to help you.

      The funniest thing about this particular signature is that by the time you realise it doesn't say anything it's too late to stop reading it. My latest tip/trick - Silverlight *.XCP files. Visit the Hindi forum here.

      1 Reply Last reply
      0
      • G gamer1127

        Hello to all. I'm having a little problem with one of the features that I want to have in my program. I want my program to search the names of the guest for every key press. For example, if I press H on the keyboard, all of the last names that starts with H should appear. I tried to use both KeyDown and KeyPress Events but either of them doesn't seem to work. Can anyone help me?

        M Offline
        M Offline
        Mycroft Holmes
        wrote on last edited by
        #3

        Why not use the textchanged event to filter the dataview.

        Never underestimate the power of human stupidity RAH

        N 1 Reply Last reply
        0
        • G gamer1127

          Hello to all. I'm having a little problem with one of the features that I want to have in my program. I want my program to search the names of the guest for every key press. For example, if I press H on the keyboard, all of the last names that starts with H should appear. I tried to use both KeyDown and KeyPress Events but either of them doesn't seem to work. Can anyone help me?

          P Offline
          P Offline
          PIEBALDconsult
          wrote on last edited by
          #4

          Have you considered using autocomplete or whatever it is?

          1 Reply Last reply
          0
          • G gamer1127

            Hello to all. I'm having a little problem with one of the features that I want to have in my program. I want my program to search the names of the guest for every key press. For example, if I press H on the keyboard, all of the last names that starts with H should appear. I tried to use both KeyDown and KeyPress Events but either of them doesn't seem to work. Can anyone help me?

            L Offline
            L Offline
            Lost User
            wrote on last edited by
            #5

            Where are the customers list stored ?

            I know nothing , I know nothing ...

            N 1 Reply Last reply
            0
            • L Lost User

              Where are the customers list stored ?

              I know nothing , I know nothing ...

              N Offline
              N Offline
              Not Active
              wrote on last edited by
              #6

              Why does it matter?


              I know the language. I've read a book. - _Madmatt

              J 1 Reply Last reply
              0
              • M Mycroft Holmes

                Why not use the textchanged event to filter the dataview.

                Never underestimate the power of human stupidity RAH

                N Offline
                N Offline
                Not Active
                wrote on last edited by
                #7

                Doesn't the OnTextChanged event fire after the textbox looses focus? That would be too late for this purpose, I believe the OP wants type-ahead lookup functionality


                I know the language. I've read a book. - _Madmatt

                M 1 Reply Last reply
                0
                • N Not Active

                  Doesn't the OnTextChanged event fire after the textbox looses focus? That would be too late for this purpose, I believe the OP wants type-ahead lookup functionality


                  I know the language. I've read a book. - _Madmatt

                  M Offline
                  M Offline
                  Mycroft Holmes
                  wrote on last edited by
                  #8

                  Mark Nischalke wrote:

                  Doesn't the OnTextChanged event fire after the textbox looses focus

                  I'll need to go check this, I was under the impression it would fire at each change of content.

                  Never underestimate the power of human stupidity RAH

                  N 1 Reply Last reply
                  0
                  • M Mycroft Holmes

                    Mark Nischalke wrote:

                    Doesn't the OnTextChanged event fire after the textbox looses focus

                    I'll need to go check this, I was under the impression it would fire at each change of content.

                    Never underestimate the power of human stupidity RAH

                    N Offline
                    N Offline
                    Not Active
                    wrote on last edited by
                    #9

                    Had to check also. Winforms it raises the event while typing, in Web its raised after loosing focus


                    I know the language. I've read a book. - _Madmatt

                    M 1 Reply Last reply
                    0
                    • N Not Active

                      Had to check also. Winforms it raises the event while typing, in Web its raised after loosing focus


                      I know the language. I've read a book. - _Madmatt

                      M Offline
                      M Offline
                      Mycroft Holmes
                      wrote on last edited by
                      #10

                      Being a winforms developer I did not even consider the webform activity. Talk about a narrow view on life. I would not have considered this a viable solution on a webform, you would have to resort to (spit) javascript or ajax to get any sort of reasonable response.

                      Never underestimate the power of human stupidity RAH

                      1 Reply Last reply
                      0
                      • N Not Active

                        Why does it matter?


                        I know the language. I've read a book. - _Madmatt

                        J Offline
                        J Offline
                        J4amieC
                        wrote on last edited by
                        #11

                        If they're stored on a piece of paper its going to be real difficult to write the ODBC driver ;)

                        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