Guys:
Can I disable the cancel button that shows when I'm using MsgMeter() ? I do not want users cancelling indexing operations.
Thank you.
Guys:
Can I disable the cancel button that shows when I'm using MsgMeter() ? I do not want users cancelling indexing operations.
Thank you.
//----------------------------------------------------------------------------//
function MsgMeter( bAction, cMsg, cTitle, lBoton )
local oDlg, oMeter, oText, oBtn, oFont
local lEnd := .f., lCancel := .f.
local nVal := 0
DEFAULT bAction := { || nil },;
cMsg := "Procesando...", cTitle := "Aguarde por favor",;
lBoton := .f.
DEFINE DIALOG oDlg RESOURCE "MSGMETER" COLOR "W+/B"
REDEFINE TSAYT ID 111 OF oDlg
REDEFINE TSAYT oText VAR cMsg ID 110 OF oDlg
REDEFINE METER oMeter VAR nVal TOTAL 10 ID 130 OF oDlg
**DEFINE FONT oFont NAME "Ms Sans Serif" SIZE 0, -8
**DEFINE DIALOG oDlg FROM 5, 5 TO 10.4, 45 TITLE cTitle FONT oFont
**@ 0.2, 0.5 SAY oText VAR cMsg SIZE 130, 10 OF oDlg
**@ 1, 0.5 METER oMeter VAR nVal TOTAL 10 SIZE 150, 10 OF oDlg
if lBoton
@ 2.8, 18 BUTTON oBtn PROMPT "&Cancel" OF oDlg ;
ACTION ( lEnd:= .t., lCancel:= .t. ) SIZE 32, 11
endif
// This block gets evaluated only the first time the DialogBox is painted !!!
oDlg:bStart = { || Eval( bAction, oMeter, oText, oDlg, @lEnd, oBtn ),;
lEnd := .t., oDlg:End() }
ACTIVATE DIALOG oDlg CENTERED ;
VALID lEnd
return lCancelFrancisco:
Thank you very much ! ¡ Muchas gracias !