Link to home
Start Free TrialLog in
Avatar of rcoast
rcoast

asked on

Disable, then enable the Retry Button in a MessageBox

I have the following unmanaged C++ code:

MessageBox( NULL, strMessage, "Cool Product", MB_RETRYCANCEL | MB_ICONEXCLAMATION);

I want to disable the RETRY button for 10 seconds (for example), then enable it.

How can I do this?
Avatar of specialagent8305
specialagent8305
Flag of South Africa image

You cannot (or I am not aware) do this with a message box. You have to create a custon dialog, or easiest yet... Creat a form that represents a dialog-box, with the border style as dialog... The rest should be easy... If the form should return a result, a custom dialog is best... Otherwise, a standard form should do the trick... (This is how I do it, anyway!)
Avatar of rcoast
rcoast

ASKER

Can you point me in the direction of a tutorial on how to do this? I want to avoid MFC and ATL and use only standard Win32 API calls.
ASKER CERTIFIED SOLUTION
Avatar of itsmeandnobodyelse
itsmeandnobodyelse
Flag of Germany image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial