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

close form

Scheduled Pinned Locked Moved C#
design
3 Posts 3 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
    nelsonpaixao
    wrote on last edited by
    #1

    hi, i design a application that opens a form from other form, i use the ".showdialog" ".show" methods that works fine. but a also want to close the first form when the second form loads, but i can´t manage to do that. when i trie to do that i shutdown the all application or something else!!! thanks!!!:cool:

    C N 2 Replies Last reply
    0
    • N nelsonpaixao

      hi, i design a application that opens a form from other form, i use the ".showdialog" ".show" methods that works fine. but a also want to close the first form when the second form loads, but i can´t manage to do that. when i trie to do that i shutdown the all application or something else!!! thanks!!!:cool:

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      The logical thing to do here is to make both forms laid out on user controls, then show them both in the one form.

      Christian Graus No longer a Microsoft MVP, but still happy to answer your questions.

      1 Reply Last reply
      0
      • N nelsonpaixao

        hi, i design a application that opens a form from other form, i use the ".showdialog" ".show" methods that works fine. but a also want to close the first form when the second form loads, but i can´t manage to do that. when i trie to do that i shutdown the all application or something else!!! thanks!!!:cool:

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

        You may hide the first form (Closing your start up form will close the application). Also code will stop executing at the call ".ShowDialog()", and will only continue after the user has closed the second form.

        Nirandas, a developer from India. http://www.nirandas.com

        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