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. Managed C++/CLI
  4. How to display Exception after the Form is loaded

How to display Exception after the Form is loaded

Scheduled Pinned Locked Moved Managed C++/CLI
questiontutorial
3 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
    mmhu
    wrote on last edited by
    #1

    There is an exception caught during loading the Form, but the Form will be loaded no matter what. I want to display that exception Message in front of the Form once the Form is loaded. If I use message box to display the exception Message inside the Form_load function, the Exception message box is behinde the Form. How can I make it displayed in front of the Form?:confused:

    N 1 Reply Last reply
    0
    • M mmhu

      There is an exception caught during loading the Form, but the Form will be loaded no matter what. I want to display that exception Message in front of the Form once the Form is loaded. If I use message box to display the exception Message inside the Form_load function, the Exception message box is behinde the Form. How can I make it displayed in front of the Form?:confused:

      N Offline
      N Offline
      Nish Nishant
      wrote on last edited by
      #2

      You could add a TextBox to the form and show the message in that TextBox.

      Regards, Nish


      Nish’s thoughts on MFC, C++/CLI and .NET (my blog)
      Currently working on C++/CLI in Action for Manning Publications. Also visit the Ultimate Toolbox blog (New)

      M 1 Reply Last reply
      0
      • N Nish Nishant

        You could add a TextBox to the form and show the message in that TextBox.

        Regards, Nish


        Nish’s thoughts on MFC, C++/CLI and .NET (my blog)
        Currently working on C++/CLI in Action for Manning Publications. Also visit the Ultimate Toolbox blog (New)

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

        Uhm, the parent form can't have the error message box on it. I have a class called ErrorScreen displaying error message. Then there is the main menu Form1 (1). the Form invokes function classes**(2).** These function classes invoke more basic classes**(3).** These basic classes invoke the ErrorScreen class. But the ErrorScreen instances displays strangely in front of the main menu. The error icon, the text, and the button are not displayed, but empty holes on the ErrorScreen. If the ErrorScreen instances are replaced with Forms::MessageBox::Show(),the error messages are displayed correctly. But I need big size button displayed on the error message screen, therefore I need use the ErrorScreen class created myself. What senarias I shall look into in order to display those ErrorScreens correctly?

        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