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. form close

form close

Scheduled Pinned Locked Moved C#
question
5 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.
  • M Offline
    M Offline
    mpastchenko
    wrote on last edited by
    #1

    Folks this is a simple amost silly question, but still i would like to ask: I would like to imitate form close event identical to when you presses X to close, when I click on a button for close a form. I basically want to catch all exception in from control when the button clicked. Sincerely, Max Pastchenko

    E M 3 Replies Last reply
    0
    • M mpastchenko

      Folks this is a simple amost silly question, but still i would like to ask: I would like to imitate form close event identical to when you presses X to close, when I click on a button for close a form. I basically want to catch all exception in from control when the button clicked. Sincerely, Max Pastchenko

      E Offline
      E Offline
      eggie5
      wrote on last edited by
      #2

      Can you try explaining it again? /\ |_ E X E GG

      1 Reply Last reply
      0
      • M mpastchenko

        Folks this is a simple amost silly question, but still i would like to ask: I would like to imitate form close event identical to when you presses X to close, when I click on a button for close a form. I basically want to catch all exception in from control when the button clicked. Sincerely, Max Pastchenko

        M Offline
        M Offline
        mpastchenko
        wrote on last edited by
        #3

        well, i thought this was rather a simple question.... hmmm Well here is what I tried, on the button click event, I tried calling form closing event where say textbox validation occured, but when exception is thrown, It does not get that piece of code. Sincerely, Max Pastchenko

        1 Reply Last reply
        0
        • M mpastchenko

          Folks this is a simple amost silly question, but still i would like to ask: I would like to imitate form close event identical to when you presses X to close, when I click on a button for close a form. I basically want to catch all exception in from control when the button clicked. Sincerely, Max Pastchenko

          M Offline
          M Offline
          mpastchenko
          wrote on last edited by
          #4

          Here we go again, Lets say i use this.close for close a form as this point ( when i press on a command that closes my form). I want to know an alternative way of doing so. This is because form closing event is not being called. It does get called when I press X of the form. What i want to acoomplish is trap any control value errors on form close (is text field empty or not when form closes). Does this help? Sincerely, Max Pastchenko

          M 1 Reply Last reply
          0
          • M mpastchenko

            Here we go again, Lets say i use this.close for close a form as this point ( when i press on a command that closes my form). I want to know an alternative way of doing so. This is because form closing event is not being called. It does get called when I press X of the form. What i want to acoomplish is trap any control value errors on form close (is text field empty or not when form closes). Does this help? Sincerely, Max Pastchenko

            M Offline
            M Offline
            mpastchenko
            wrote on last edited by
            #5

            Better validation check to simply validate values on text cahnged event Sincerely, Max Pastchenko

            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