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. Visual Basic
  4. Windows forms and message box

Windows forms and message box

Scheduled Pinned Locked Moved Visual Basic
winformsquestion
5 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.
  • R Offline
    R Offline
    rk4ps
    wrote on last edited by
    #1

    Hello, I am working on a windows application with MDI form. Here in FIND functionality, a find form displayed with Find button working on "Enter" key. The Find form functionality is in a different dll. I am accessing that dll to display find form on existing MDIChild form containing the data. While this form is open, any messagebox displayed from the Find form is displayed on top. but the messages that are appearing from the MDIChild form are sometimes appearing behind the Find form. Even if I opened any other form, sometimes it is also appearing behind this Find form. Please let me know how should I bring these messages/new forms on Top? Thanks in Advance, Nivedita

    E C 2 Replies Last reply
    0
    • R rk4ps

      Hello, I am working on a windows application with MDI form. Here in FIND functionality, a find form displayed with Find button working on "Enter" key. The Find form functionality is in a different dll. I am accessing that dll to display find form on existing MDIChild form containing the data. While this form is open, any messagebox displayed from the Find form is displayed on top. but the messages that are appearing from the MDIChild form are sometimes appearing behind the Find form. Even if I opened any other form, sometimes it is also appearing behind this Find form. Please let me know how should I bring these messages/new forms on Top? Thanks in Advance, Nivedita

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

      first of all plz tell wether u set the form's "topmost" property to true or false

      R 1 Reply Last reply
      0
      • R rk4ps

        Hello, I am working on a windows application with MDI form. Here in FIND functionality, a find form displayed with Find button working on "Enter" key. The Find form functionality is in a different dll. I am accessing that dll to display find form on existing MDIChild form containing the data. While this form is open, any messagebox displayed from the Find form is displayed on top. but the messages that are appearing from the MDIChild form are sometimes appearing behind the Find form. Even if I opened any other form, sometimes it is also appearing behind this Find form. Please let me know how should I bring these messages/new forms on Top? Thanks in Advance, Nivedita

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

        It's either the Owner or Parent property. You need to set one of these for all child windows, and then they can never go behind their owner.

        Christian Graus - Microsoft MVP - C++ "I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )

        1 Reply Last reply
        0
        • E eyes2007

          first of all plz tell wether u set the form's "topmost" property to true or false

          R Offline
          R Offline
          rk4ps
          wrote on last edited by
          #4

          It's in the "InitializeComponent".

          R 1 Reply Last reply
          0
          • R rk4ps

            It's in the "InitializeComponent".

            R Offline
            R Offline
            rk4ps
            wrote on last edited by
            #5

            If I set the Topmost Property to false, then for any event happening like displaying message box or opening any other form, this Find form gets minimised and loses it's focus. Can we display FindForm after closing the messageBox?

            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