none
Message Boxes in Application Never Display RRS feed

  • Question

  • Using VS 2015 Community Edition and .net 4 framework. The targeted OS is Win 7 Embedded Standard with Service Pack 1.

    What windows components are needed to display a message box (MsgBox) in an application. The Notepad application displays a message box prompting to save changed content. However, any MsgBox in an applications I have developed don't display. Can there be a difference in the OS image provided by two different venders of industrial controllers? While my application works fine in the box provided by one vender, the same software does not display the MsgBox in the box provided by a different vender.

    Thanks,

    RBO

    Monday, September 5, 2016 9:32 PM

Answers

  • Sean Liming already points into the right direction - I see 2 possibilities: One of your systems is Windows Embedded Standard 7 (WES7) and the other not is another O/S like Windows 7 Professional - or both of them have Windows Embedded Standard 7 O/S but differ in the components that have been added to the image.

    The behaviour is usually caused by an WES7 (embbedded enabling) feature called "Dialog Box Filter". My experience is that it is enabled per default once it was added to the image. In this case all message boxes will not show, and their "default button" (the one that get the foces when shown) has been "clicked" automatically. You also may see Events in the "Applicaton" event Log, their description should contain that text that was displayed on the message box.

    The easiest way to get rid of that is to modify the registry in HKLM\System\CurrentControlSet\Control\Error Message Instrument:

    REG_DWORD EnableDefaultReply
        0 = "Disable" clicking the "default button"    1 = "Enable" clicking the "default button"

    REG_DWORD EnableLogging
        0 = Do not log message boxes that have been handled by Dialog box filter (Application Log)
        1 = Llog message boxes that have been handled by Dialog box filter (Application Log)

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:36 PM
    Tuesday, September 6, 2016 7:26 AM
  • Did you build the Windows Embedded Standard 7 image or did it come on a system as is?

    If the later, the person or company that put the image together might have included a feature to disable message boxes.


    Sean Liming - Book Author: Starter Guide SIM (WEI), Pro Guide to WE8S & WES 7, Pro Guide to POS for .NET - www.annabooks.com / www.seanliming.com

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:37 PM
    Tuesday, September 6, 2016 3:37 AM
    Moderator
  • Making recommended changes to the registry worked.

    Thanks for the help.

    RBO

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:37 PM
    Tuesday, September 6, 2016 7:37 PM

All replies

  • Did you build the Windows Embedded Standard 7 image or did it come on a system as is?

    If the later, the person or company that put the image together might have included a feature to disable message boxes.


    Sean Liming - Book Author: Starter Guide SIM (WEI), Pro Guide to WE8S & WES 7, Pro Guide to POS for .NET - www.annabooks.com / www.seanliming.com

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:37 PM
    Tuesday, September 6, 2016 3:37 AM
    Moderator
  • Sean Liming already points into the right direction - I see 2 possibilities: One of your systems is Windows Embedded Standard 7 (WES7) and the other not is another O/S like Windows 7 Professional - or both of them have Windows Embedded Standard 7 O/S but differ in the components that have been added to the image.

    The behaviour is usually caused by an WES7 (embbedded enabling) feature called "Dialog Box Filter". My experience is that it is enabled per default once it was added to the image. In this case all message boxes will not show, and their "default button" (the one that get the foces when shown) has been "clicked" automatically. You also may see Events in the "Applicaton" event Log, their description should contain that text that was displayed on the message box.

    The easiest way to get rid of that is to modify the registry in HKLM\System\CurrentControlSet\Control\Error Message Instrument:

    REG_DWORD EnableDefaultReply
        0 = "Disable" clicking the "default button"    1 = "Enable" clicking the "default button"

    REG_DWORD EnableLogging
        0 = Do not log message boxes that have been handled by Dialog box filter (Application Log)
        1 = Llog message boxes that have been handled by Dialog box filter (Application Log)

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:36 PM
    Tuesday, September 6, 2016 7:26 AM
  • Making recommended changes to the registry worked.

    Thanks for the help.

    RBO

    • Marked as answer by ROberholz Tuesday, September 6, 2016 7:37 PM
    Tuesday, September 6, 2016 7:37 PM
  • Also see (for reference):Enabling Default Reply (Registry Reference)

    Christopher Scholten 龘龗蘇


    Friday, October 19, 2018 5:12 PM