PROCEDURE prdForm_Cmg
.Top=fncT(125)
.Left=fncL(007)
.Width=.Parent.Width-fncW(015)
.Height=.Parent.Height-.Top-fncH(010)
.BackColor=.Parent.BackColor
.BorderStyle=0
.ButtonCount=64
.SetAll([Height],.Height*4/.ButtonCount)
.SetAll([Caption],SPACE(0))
.SetAll([FontName],[Arial])
.SetAll([SpecialEffect],2)
FOR m.nBx=1 TO .ButtonCount
WITH .Buttons[m.nBx]
.Top=INT((m.nBx-1)/4)*.Height+fncT(2.5)
.Left=ICASE(m.nBx%4=1,fncL(2.5),m.nBx%4=2,fncL(47.5),m.nBx%4=3,fncL(72.5),fncL(97.5))
.Width=ICASE(m.nBx%4=1,fncW(045),m.nBx%4=0,fncW(035),fncW(025))
.Alignment=IIF(m.nBx%4=1 OR m.nBx<5,2,1)
.ForeColor=ICASE(m.nBx<5,125,m.nBx%4!=1,16711935,0)
.FontBold=IIF(m.nBx<5,.T.,.F.)
.FontSize=IIF(m.nBx<5,12,9)
ENDWITH
NEXT
.Buttons[1].Caption=fncTran([Reminding])
.Buttons[2].Caption=fncTran([Expired])
.Buttons[3].Caption=fncTran([Forecast])
.Buttons[4].Caption=fncTran([Total])
SCAN FOR SEEK(ALLTRIM(y_Rmnd.cTbl_en),[i_Tbls],1)=.T.
DO prdFetch_Remind WITH 0,DATE()+y_Rmnd.nDay,.T.
ENDSCAN
FOR m.nBx=.ButtonCount-3 TO .ButtonCount-0
.Buttons[m.nBx].Height=.Buttons[m.nBx].Height-fncH(001)
NEXT
.Buttons[.ButtonCount-3].Caption=IIF(m.nSum+m.nSun=0,SPACE(0),fncTran([Total]))
.Buttons[.ButtonCount-2].Caption=IIF(m.nSum=0,SPACE(0),TRANSFORM(m.nSum,[99,999]))
.Buttons[.ButtonCount-1].Caption=IIF(m.nSun=0,SPACE(0),TRANSFORM(m.nSun,[99,999]))
.Buttons[.ButtonCount-0].Caption=IIF(m.nSum+m.nSun=0,SPACE(0),TRANSFORM(m.nSum+m.nSun,[99,999]))
ENDPROC