I have these constants
#constant MsgOKOnly = 0
#constant MsgOKCancel = 1
#constant MsgAbortRetryIgnore = 2
#constant MsgYesNoCancel = 3
#constant MsgYesNo = 4
#constant MsgRetryCancel = 5
`
#constant MsgCritical = 16
#constant MsgQuestion = 32
#constant MsgExclamation = 48
#constant MsgInformation = 64
`
#constant MsgDefaultButton1 = 0
#constant MsgDefaultButton2 = 256
#constant MsgDefaultButton3 = 512
`
#constant MsgApplicationModal = 0
#constant MsgSystemModal = 4096
`return values
#constant MsgOK = 1
#constant MsgCancel = 2
#constant MsgAbort = 3
#constant MsgRetry = 4
#constant MsgIgnore = 5
#constant MsgYes = 6
#constant MsgNo = 7
to be used with
function msgbox(msg as string,opts as integer,title as string)
`returns -1 if fail (all dll slots taken)
local dll_num as integer : local hwnd as integer
local response as integer
dll_num = free_dll()
if dll_num > 0
load dll "user32.dll",dll_num
hwnd = call dll (dll_num,"GetActiveWindow")
response = call dll (dll_num,"MessageBoxA",hwnd,msg,title,opts)
delete dll dll_num
else
response = -1
endif
endfunction response
function free_dll()
local i as integer : stop as integer
repeat
inc i
if i < 256 then if dll exist(i)=0 then stop = 1
until stop = 1 or i > 255
if i > 255 then i = 0
endfunction i
and I was wondering if I can have buttons say things like Bob Randy Cancel...
Thanks in advance,
Jim
Insert Signature Here