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#
  4. .NET has a BUG???

.NET has a BUG???

Scheduled Pinned Locked Moved C#
csharphelpquestion
3 Posts 2 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.
  • R Offline
    R Offline
    Radgar
    wrote on last edited by
    #1

    I'm not sure but, in _KeyPress event of a textbox, if you add the code "e.Handled = true;", it works fine. The event is cancelled. But in _KeyDown event it doesn't work. private void t2_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e) { e.Handled = true; } Is this a bug? or am I missing something? Radgar "Imagination is more important than knowledge." - Albert Einstein

    S 1 Reply Last reply
    0
    • R Radgar

      I'm not sure but, in _KeyPress event of a textbox, if you add the code "e.Handled = true;", it works fine. The event is cancelled. But in _KeyDown event it doesn't work. private void t2_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e) { e.Handled = true; } Is this a bug? or am I missing something? Radgar "Imagination is more important than knowledge." - Albert Einstein

      S Offline
      S Offline
      S Senthil Kumar
      wrote on last edited by
      #2

      Yes, it's a bug, it has been fixed in .NET 2.0 Regards Senthil

      R 1 Reply Last reply
      0
      • S S Senthil Kumar

        Yes, it's a bug, it has been fixed in .NET 2.0 Regards Senthil

        R Offline
        R Offline
        Radgar
        wrote on last edited by
        #3

        Thanks Senthil.. Same goes for ComboBox control too.. Radgar "Imagination is more important than knowledge." - Albert Einstein

        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