calendario com DTPICKER!
Posted: Sat Sep 08, 2007 2:37 pm
Antonio, usando o controle do PELLES (calendario) criei um funcao para calendario, e funcionou bem, a não ser por não estar aceitando a navegação com a teclas <- -> , e superior e inferior...
*************************************************
FUNCTION Calend(dDate,nRow,nCol,oDlg)
*************************************************
LOCAL oDlf,lSel:=.F.,oCalend,dDataCalend:=date()
DEFINE DIALOG oDlf RESOURCE "Calend2" FONT oWnd:oFont ICON OICO color CLR_WHITE,CLR_WHITE
REDEFINE DTPICKER oCalend VAR dDataCalend ID 4001 OF oDlf
REDEFINE BUTTON ID 104 OF oDlf ACTION (lSel:=.T.,dDate:=dDataCalend,oDlf:End())
REDEFINE BUTTON ID 103 OF oDlf ACTION (oDlf:End())
oDlf:lHelpicon :=.F.
ACTIVATE DIALOG oDlf ON INIT(If(ValType( nRow ) != "N",WndCenter( oDlf:hWnd ), ;
oDlf:Move( nRow, nCol ) ),oDlf:Box( 39, 8, 157, 142))
RETURN(dDate)
*************************************************
FUNCTION Calend(dDate,nRow,nCol,oDlg)
*************************************************
LOCAL oDlf,lSel:=.F.,oCalend,dDataCalend:=date()
DEFINE DIALOG oDlf RESOURCE "Calend2" FONT oWnd:oFont ICON OICO color CLR_WHITE,CLR_WHITE
REDEFINE DTPICKER oCalend VAR dDataCalend ID 4001 OF oDlf
REDEFINE BUTTON ID 104 OF oDlf ACTION (lSel:=.T.,dDate:=dDataCalend,oDlf:End())
REDEFINE BUTTON ID 103 OF oDlf ACTION (oDlf:End())
oDlf:lHelpicon :=.F.
ACTIVATE DIALOG oDlf ON INIT(If(ValType( nRow ) != "N",WndCenter( oDlf:hWnd ), ;
oDlf:Move( nRow, nCol ) ),oDlf:Box( 39, 8, 157, 142))
RETURN(dDate)