Dear All,
I've a problem with TGET VALID clause. Because it will now process if the user PRESS ESC key.
How can I force to pass the VALID before leave its input field ? The sample is oGet1, it can input Charactor like "A" and press ESC the Variable will keep "A" without check VALID clause.
Thanks in advance for any help and idea.
I've a problem with TGET VALID clause. Because it will now process if the user PRESS ESC key.
How can I force to pass the VALID before leave its input field ? The sample is oGet1, it can input Charactor like "A" and press ESC the Variable will keep "A" without check VALID clause.
Thanks in advance for any help and idea.
// Testing GETs
#include "FiveWin.ch"
function Main()
LOCAL oDlg, oGet, oGet1
LOCAL cCad := space(20) // "Testing " // pad("Testing Gets",40)
LOCAL nNum := 0
LOCAL dDat := Date()
Set century On
Set Date Ansi
Set Date format "mm/dd/yyyy"
SET _3DLOOK ON
DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION
@ 1, 2 SAY "Text..:" OF oDlg
@ 1, 6 GET oGet1 VAR cCad OF oDlg SIZE 60, 10 COLOR "W/G" PICTURE "@K" ;
VALID iif(cCad $ '1234567890',.T.,(MsgStop('wrong input'), .F.))
@ 1.8, 2 SAY "Number:" OF oDlg
@ 2, 6 GET oGet VAR nNum OF oDlg SIZE 60, 10 PICTURE "9999999.99"
@ 2.6, 2 SAY "Date:" OF oDlg
@ 3, 6 GET oGet VAR dDat PICTURE "@E" OF oDlg SIZE 60, 10 // "@D"
@ 3, 7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION oDlg:End()
@ 3, 16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL
// TGet():SetColorFocus( nRGB( 200, 120, 120 ) )
ACTIVATE DIALOG oDlg CENTERED
msginfo( cCad )
return nilRegards,
Dutch
FWH 2304 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio
FWPPC 10.02 / Harbour for PPC (FTDN)
ADS V.9 / MySql / MariaDB
R&R 12 Infinity / Crystal Report XI R2
(Thailand)
Dutch
FWH 2304 / xHarbour Simplex 1.2.3 / BCC73 / Pelles C / UEStudio
FWPPC 10.02 / Harbour for PPC (FTDN)
ADS V.9 / MySql / MariaDB
R&R 12 Infinity / Crystal Report XI R2
(Thailand)