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. Topmost Form

Topmost Form

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

    How can I make a form ALWAYS topmost regardless if another form within the project has been set to topmost? Thanks in advance. P

    N D 2 Replies Last reply
    0
    • P PHDENG81

      How can I make a form ALWAYS topmost regardless if another form within the project has been set to topmost? Thanks in advance. P

      N Offline
      N Offline
      NaNg15241
      wrote on last edited by
      #2

      try adding to your database at your forum-msgs table another field called "Type", you should probably use numbers for this. when you call for your messages at your page, try putting first the ones with type = 1, and later get the others. this is a prioraty for your messages, then you can arrange them.

      D 1 Reply Last reply
      0
      • N NaNg15241

        try adding to your database at your forum-msgs table another field called "Type", you should probably use numbers for this. when you call for your messages at your page, try putting first the ones with type = 1, and later get the others. this is a prioraty for your messages, then you can arrange them.

        D Offline
        D Offline
        Dave Kreskowiak
        wrote on last edited by
        #3

        Ummm....And this has what to do with making a form TopMost??? :confused: RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

        N 1 Reply Last reply
        0
        • D Dave Kreskowiak

          Ummm....And this has what to do with making a form TopMost??? :confused: RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

          N Offline
          N Offline
          NaNg15241
          wrote on last edited by
          #4

          hmmm... escuse me for being new here and not knowing **** about anything... but now i get what he sais... sorry :-O

          P D 2 Replies Last reply
          0
          • N NaNg15241

            hmmm... escuse me for being new here and not knowing **** about anything... but now i get what he sais... sorry :-O

            P Offline
            P Offline
            PHDENG81
            wrote on last edited by
            #5

            So, is there a way to do this? Thanks

            N 1 Reply Last reply
            0
            • P PHDENG81

              So, is there a way to do this? Thanks

              N Offline
              N Offline
              NaNg15241
              wrote on last edited by
              #6

              well... i think that the best solution is that when you show it, you use the command form.showdialog() insted of form.show, this way it won't enable it to go to the last one... that's the best option that i could think of, i don't think that you can do topmost with some other and not enable it to switch forms... unless... you can do an event "On leave", and then do a focus command on the form, that way if you leave, it will get focused on the form and wouldn't be able to switch... i think that that would work. no moer options for me... good-luck, NaNg

              P 1 Reply Last reply
              0
              • N NaNg15241

                hmmm... escuse me for being new here and not knowing **** about anything... but now i get what he sais... sorry :-O

                D Offline
                D Offline
                Dave Kreskowiak
                wrote on last edited by
                #7

                Hey, no offense. We just found it really odd that the OP kind of asked a question about, say, washing a dog, and you gave him instructions on aging cheese. :confused::confused::confused::confused: We thought you posted a reply to a question, but clicked on the wrong Reply link. That's how far off topic you were! RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

                1 Reply Last reply
                0
                • P PHDENG81

                  How can I make a form ALWAYS topmost regardless if another form within the project has been set to topmost? Thanks in advance. P

                  D Offline
                  D Offline
                  Dave Kreskowiak
                  wrote on last edited by
                  #8

                  Well, off the top of my head, you have a problem. Your app can only have one TopMost form. The one that gets set to TopMost LAST stays there. Ther previous ones get knocked down the z-order. It looks like you're going to have to manage your TopMost property a bit more carefully, and sparingly. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

                  1 Reply Last reply
                  0
                  • N NaNg15241

                    well... i think that the best solution is that when you show it, you use the command form.showdialog() insted of form.show, this way it won't enable it to go to the last one... that's the best option that i could think of, i don't think that you can do topmost with some other and not enable it to switch forms... unless... you can do an event "On leave", and then do a focus command on the form, that way if you leave, it will get focused on the form and wouldn't be able to switch... i think that that would work. no moer options for me... good-luck, NaNg

                    P Offline
                    P Offline
                    PHDENG81
                    wrote on last edited by
                    #9

                    Thanks for the help guys. P

                    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