четвъртък, 21 април 2011 г.

(Lesson №1) MsgBox - Flags & Params

MsgBox Command - MsgBox(flag,"title","text" ,timeout,hwnd)

Params:
Param - Purpose
flag - Sets buttons, icons, etc.
title - Sets the title of the box.
text - Sets the text within the box.
timeout - Sets the number of seconds till close.(Optional)
hwnd - Sets the window handle as the parent.(Optional)

Flags:
Value - Result
0 - OK
1 - OK, Cancel
2 - Abort, Retry, Ignore
3 - Yes, No, Cancel
4 - Yes, No
5 - Retry, Cancel
6 - Cancel, Try Again, Continue (>= Win2k)
16 - Stop Sign Icon
32 - Question Mark Icon
48 - Exclamation Point Icon
64 - Info Bubble Icon
256 - Set Second Button to default
512 - Set Third Button to default
4096 - System modal (dialog has an icon)
8192 - Task modal
262144 - MsgBox ahs top-most attribute set
524288 - Title and Text are right-justified

 

I will give an example:

MsgBox(4,"Answer fast!","Is it OK?",3) ;

The MsgBox will close after 3 seconds
Buttons will be: Yes,No


Няма коментари:

Публикуване на коментар