home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Pier Shareware 6
/
The_Pier_Shareware_Number_6_(The_Pier_Exchange)_(1995).iso
/
035
/
cenvi29.zip
/
MSGBOXES.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1994-03-08
|
1KB
|
34 lines
EXTPROC CEnvi
/*************************************************************
*** MsgBoxes - Sample Cmm code to demonstrate uses of the ***
*** ver.1 MessageBox() function. ***
*************************************************************/
#include <MsgBox.lib>
MessageBox("The following samples show various ways\n"
"to use the Windows MessageBox() function.\n"
"A wrapper for MessageBox() is located in\n"
"the Cmm library: \"MsgBox.lib\"",
"MsgBoxes - Welcome!");
MessageBox("This example only passes 1 parameter: the message string.");
MessageBox("This passes the message string and a title.\nThis box is also moveable",
"Here is the title.",MB_MOVEABLE);
MessageBox("This example passes a zero-length string to get no title.","");
MessageBox("This box might appear after a nasty error.",NULL,MB_ERROR);
switch ( MessageBox("You can also offer different choices.\nPick one now...",
"MessageBox() choices",
MB_YESNOCANCEL) ) {
case MBID_YES: button = "Yes"; break;
case MBID_NO: button = "No"; break;
case MBID_CANCEL: button = "Cancel"; break;
}
sprintf(message,"You selected the %s button",button);
MessageBox(message,"");