skip original event handler.

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jayson

    #1

    skip original event handler.

    Hi guys,

    I am using a control(I only got the dll file) downloaded from web.
    Whenever a key is enter it will validate the user input. If not valid
    it will ignore the key being enter. I want to skip that validation
    handler. How do I do that?
    Thank you!

  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: skip original event handler.

    Jayson,

    Unless the control offers a method or property you can set to change
    this behavior, you can't do anything about it. Only a control itself has
    access to the events, and only it can fire them or skip them.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Jayson" <sc_tang@hartap ack.com> wrote in message
    news:1136172780 .725299.11220@g 44g2000cwa.goog legroups.com...[color=blue]
    > Hi guys,
    >
    > I am using a control(I only got the dll file) downloaded from web.
    > Whenever a key is enter it will validate the user input. If not valid
    > it will ignore the key being enter. I want to skip that validation
    > handler. How do I do that?
    > Thank you!
    >[/color]


    Comment

    • Joanna Carter [TeamB]

      #3
      Re: skip original event handler.

      "Jayson" <sc_tang@hartap ack.com> a écrit dans le message de news:
      1136172780.7252 99.11220@g44g20 00...legro ups.com...

      | I am using a control(I only got the dll file) downloaded from web.
      | Whenever a key is enter it will validate the user input. If not valid
      | it will ignore the key being enter. I want to skip that validation
      | handler. How do I do that?

      It is meant to be a common design practice to have an event like Click fired
      by a method like OnClick. The OnClick method could well be virtual and
      therefore, overriding this method could allow you to prevent the event being
      called by making the override an empty method.

      Look for a method on the control called On(WhateverTheE vent).

      Joanna

      --
      Joanna Carter [TeamB]
      Consultant Software Engineer


      Comment

      Working...