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. Windows Forms
  4. Leave event is not working.

Leave event is not working.

Scheduled Pinned Locked Moved Windows Forms
questiondatabasehelp
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.
  • N Offline
    N Offline
    nitish_07
    wrote on last edited by
    #1

    private void rtb_leave(object sender, EventArgs e)
    {
    Class1.query = rtb.Text;
    }

    private void InitializeComponent()
    {
    this.rtb = new System.Windows.Forms.RichTextBox();
    this.rtb.Leave += new System.EventHandler(this.rtb_leave);
    }

    I have done this coding...But leave event is not working..what is the problem??

    L 1 Reply Last reply
    0
    • N nitish_07

      private void rtb_leave(object sender, EventArgs e)
      {
      Class1.query = rtb.Text;
      }

      private void InitializeComponent()
      {
      this.rtb = new System.Windows.Forms.RichTextBox();
      this.rtb.Leave += new System.EventHandler(this.rtb_leave);
      }

      I have done this coding...But leave event is not working..what is the problem??

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      if this is actual code, then: 1) it is ugly (Class1 is not a good name for a class; a property should be CamelCased); 2) you can't leave a Control that isn't part of some Container (such as a Form), and hence invisible. and if it isn't we can not help you as actual code is required. :)

      Luc Pattyn [My Articles] Nil Volentibus Arduum

      N 1 Reply Last reply
      0
      • L Luc Pattyn

        if this is actual code, then: 1) it is ugly (Class1 is not a good name for a class; a property should be CamelCased); 2) you can't leave a Control that isn't part of some Container (such as a Form), and hence invisible. and if it isn't we can not help you as actual code is required. :)

        Luc Pattyn [My Articles] Nil Volentibus Arduum

        N Offline
        N Offline
        nitish_07
        wrote on last edited by
        #3

        thanks...somehow i managed with other logic.....:)

        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