locked
Custom Buttons in a MsgBox RRS feed

  • Question

  • Hi all,

    Is it possible to create a MsgBox where you can put a couple of buttons with your own Text on the buttons? At the moment it seems we are just limited to the default ones like OkCancel, YesNoCancel etc.

    I need a quick prompt (without using a new form) where the user decided whether to "Open for Viewing" or "Open for Editing", that's all, just two buttons.

    Thanks,

    A

    Friday, August 11, 2017 10:32 AM

Answers

  • What causes the need for the two buttons in the first place? Does the user click a button then you want to show the msg box with the two choices? Perhaps you can just use two buttons in the first place. Button 1 is open for viewing and button 2 is open for editing. Instead of a button that leads to a message box with two more buttons.


    Otherwise you are looking at using apis to modify the msg box as in this thread:

    https://stackoverflow.com/questions/234774/custom-button-captions-in-net-messagebox

    Or you can just make a new form with the buttons you want.

    • Marked as answer by Aronics Friday, August 11, 2017 11:53 AM
    Friday, August 11, 2017 11:41 AM

All replies

  • What causes the need for the two buttons in the first place? Does the user click a button then you want to show the msg box with the two choices? Perhaps you can just use two buttons in the first place. Button 1 is open for viewing and button 2 is open for editing. Instead of a button that leads to a message box with two more buttons.


    Otherwise you are looking at using apis to modify the msg box as in this thread:

    https://stackoverflow.com/questions/234774/custom-button-captions-in-net-messagebox

    Or you can just make a new form with the buttons you want.

    • Marked as answer by Aronics Friday, August 11, 2017 11:53 AM
    Friday, August 11, 2017 11:41 AM
  • Ah right I see. Makes sense. Thanks a lot for your answer.
    Friday, August 11, 2017 11:53 AM