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 / C++ / MFC
  4. AfxMessageBox

AfxMessageBox

Scheduled Pinned Locked Moved C / C++ / MFC
10 Posts 6 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.
  • S Offline
    S Offline
    shir_k
    wrote on last edited by
    #1

    Hi, When i include AfxMessageBox i get exit icon on the top right side of the message box, Is there any way to remove that. Thanks in advance

    D M M 3 Replies Last reply
    0
    • S shir_k

      Hi, When i include AfxMessageBox i get exit icon on the top right side of the message box, Is there any way to remove that. Thanks in advance

      D Offline
      D Offline
      David Crow
      wrote on last edited by
      #2

      shir_k wrote:

      Is there any way to remove that.

      My guess is, not without also removing the caption. You could always roll your own message box.


      "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

      "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

      S 1 Reply Last reply
      0
      • S shir_k

        Hi, When i include AfxMessageBox i get exit icon on the top right side of the message box, Is there any way to remove that. Thanks in advance

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

        Yes, there is probably a way to remove it (I think you have to look at how to remove the system menu or something like that). But the question I'm asking is why do you want to remove it ? it's part of the normal Windows UI guidelines.


        Maximilien Lincourt Your Head A Splode - Strong Bad

        S 1 Reply Last reply
        0
        • D David Crow

          shir_k wrote:

          Is there any way to remove that.

          My guess is, not without also removing the caption. You could always roll your own message box.


          "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

          "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

          S Offline
          S Offline
          shir_k
          wrote on last edited by
          #4

          Thanks for the reply. 1)How to remove the caption? 2)Own message box means i have to create new dialog box in resource view and display the message or is there any other method.

          1 Reply Last reply
          0
          • M Maximilien

            Yes, there is probably a way to remove it (I think you have to look at how to remove the system menu or something like that). But the question I'm asking is why do you want to remove it ? it's part of the normal Windows UI guidelines.


            Maximilien Lincourt Your Head A Splode - Strong Bad

            S Offline
            S Offline
            shir_k
            wrote on last edited by
            #5

            I just want to pop up a message to the user indicating "data is going to load please wait for sometime", It is just a information and data will be loaded even if user press "OK" or cancel button so i wanted to remove it.

            D M P N 4 Replies Last reply
            0
            • S shir_k

              I just want to pop up a message to the user indicating "data is going to load please wait for sometime", It is just a information and data will be loaded even if user press "OK" or cancel button so i wanted to remove it.

              D Offline
              D Offline
              David Crow
              wrote on last edited by
              #6

              It sounds like you want a modeless diaog instead so that the main thread is not blocked.


              "Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

              "To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne

              1 Reply Last reply
              0
              • S shir_k

                I just want to pop up a message to the user indicating "data is going to load please wait for sometime", It is just a information and data will be loaded even if user press "OK" or cancel button so i wanted to remove it.

                M Offline
                M Offline
                Maximilien
                wrote on last edited by
                #7

                So, there are no specific requirements to remove the "X" in the caption, so just leave it like that and concentrate on the the real features and/or other technical challenges that you might have.


                Maximilien Lincourt Your Head A Splode - Strong Bad

                1 Reply Last reply
                0
                • S shir_k

                  Hi, When i include AfxMessageBox i get exit icon on the top right side of the message box, Is there any way to remove that. Thanks in advance

                  M Offline
                  M Offline
                  Michael Dunn
                  wrote on last edited by
                  #8

                  Any message box that can be dismissed with ESC will have a close button. That's just how it works.

                  --Mike-- Visual C++ MVP :cool: LINKS~! PimpFish | CP SearchBar v3.0 | C++ Forum FAQ "That's what's great about doing user interface work. No matter what you do, people will say that what you did was idiotic." -- Raymond Chen

                  1 Reply Last reply
                  0
                  • S shir_k

                    I just want to pop up a message to the user indicating "data is going to load please wait for sometime", It is just a information and data will be loaded even if user press "OK" or cancel button so i wanted to remove it.

                    P Offline
                    P Offline
                    Paresh Chitte
                    wrote on last edited by
                    #9

                    Then why can't you use progress bar ?? Regards, Paresh.

                    1 Reply Last reply
                    0
                    • S shir_k

                      I just want to pop up a message to the user indicating "data is going to load please wait for sometime", It is just a information and data will be loaded even if user press "OK" or cancel button so i wanted to remove it.

                      N Offline
                      N Offline
                      Nelek
                      wrote on last edited by
                      #10

                      Click on the X button will give you back the IDCANCEL return value, as if you had pressed ESC or "Cancel" button.

                      Greetings. -------- M.D.V. ;) If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about? Help me to understand what I'm saying, and I'll explain it better to you “The First Rule of Program Optimization: Don't do it. The Second Rule of Program Optimization (for experts only!): Don't do it yet.” - Michael A. Jackson

                      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