                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   VERSION =   3.00      dataenvironment      dataenvironment      Dataenvironment      Name = "Dataenvironment"
      1      1      t_formretrieve      ..\libs\t_base.vcx      form      frmWhatMonth      Height = 340
Width = 115
DoCreate = .T.
Caption = "Select month"
AlwaysOnTop = .T.
umonthreturntype = 
nwhatmonth = 0
ureturnvalue = .F.
Name = "frmWhatMonth"
     |PROCEDURE abrmnth
PARAMETERS mo_param
PRIVATE mo_param, CMONTH, rvalue
************************************************************
*  abrmonth(<expN/D>)                                      *
*  Note: Function is passed a numeric parameter denoting   *
*  the month or a date.  After checking, function return   *
*  to calling program a three-character string containing  *
*  the abbreviation for the month.                         *
************************************************************
DO CASE
CASE TYPE('mo_param') = 'D'
   CMONTH = CMONTH(mo_param)
   rvalue = SUBSTR(CMONTH,1,3) + '.'
CASE TYPE('mo_param') = 'N'
   IF mo_param < 0 .OR. mo_param > 12
      = poperror('The numeric parameter passed to '+;
         'ABRMONTH is not between 1 and 12.  '+;
         'Function will return "***".')
      RETURN('***')
   ELSE
   		tmpdate = '1988,'+ LTRIM(STR(mo_param)) + ',01'
		rvalue = SUBSTR(CMONTH(DATE(&tmpdate)),1,3) + '.'

*!*		      rvalue = SUBSTR(CMONTH(CTOD(LTRIM(STR(mo_param))+;
*!*		         '/1' + '/88')),1,3) + '.'
   ENDIF
OTHERWISE
   = poperror('Invalid parameter passed to ABRMONTH.  '+;
      'Function will return "***".')
   RETURN('***')
ENDCASE
IF rvalue = 'May.'
   rvalue = 'May'
ENDIF
RETURN(rvalue)

ENDPROC
PROCEDURE Release
*!*	IF thisform.uMonthReturnType ='N'
*!*		thisform.uReturnValue = ThisForm.cmgMonth.value
*!*	ELSE
*!*		thisform.uReturnValue = thisform.abrmnth(ThisForm.cmgMonth.value)
*!*	ENDIF
IF thisform.nWhatMonth < 13
	IF thisform.uMonthReturnType ='N'
		thisform.uReturnValue = ThisForm.nWhatMonth
	ELSE
		thisform.uReturnValue = thisform.abrmnth(ThisForm.nWhatMonth)
	ENDIF
ELSE
	thisform.uReturnValue = ''
ENDIF

ENDPROC
PROCEDURE Init
PARAMETERS Alpha

IF PARAMETERS() > 0
	IF Alpha = 'N'
		thisform.uMonthReturnType = 'N'
	ENDIF
ELSE
	thisform.uMonthReturnType = 'C'
ENDIF
		
ENDPROC
                                         %   P       e      _             U   
     U  THISFORM RELEASE Click,     1  1                       !       )                                                               %   l             {             U    T   
     U  THISFORM
 NWHATMONTH RELEASE Click,     1  1                       ;       )                            !Arial, 0, 9, 5, 15, 12, 13, 3, 0
      PBorderWidth = 2
Height = 297
Left = 11
Top = 8
Width = 0
Name = "T_line1"
      frmWhatMonth      T_line1      line      ..\libs\t_base.vcx      t_line      OBorderWidth = 2
Height = 0
Left = 12
Top = 8
Width = 89
Name = "T_line3"
      frmWhatMonth      T_line3      line      ..\libs\t_base.vcx      t_line      lBorderWidth = 2
Height = 0
Left = 11
Top = 306
Width = 92
BorderColor = 255,255,255
Name = "T_line6"
      frmWhatMonth      T_line6      line      ..\libs\t_base.vcx      t_line      mBorderWidth = 2
Height = 295
Left = 103
Top = 10
Width = 0
BorderColor = 255,255,255
Name = "T_line5"
      frmWhatMonth      T_line5      line      ..\libs\t_base.vcx      t_line      )umonthreturntype
nwhatmonth
*abrmnth 
      t_commandbutton      ..\libs\t_base.vcx      commandbutton      	cmdCancel      frmWhatMonth      WTop = 314
Left = 20
Height = 22
Width = 75
Caption = "Cancel"
Name = "cmdCancel"
      FPROCEDURE Click
thisform.nWhatMonth = 13
thisform.release
ENDPROC
      ,PROCEDURE Click
thisform.release
ENDPROC
      frmWhatMonth      cmgMonth      commandgroup      ..\libs\t_base.vcx      t_commandgroup     ]ButtonCount = 12
BackStyle = 0
Value = 1
ControlSource = "thisform.nWhatMonth"
Height = 300
Left = 10
TerminateRead = .T.
Top = 7
Width = 94
Name = "cmgMonth"
Command1.Top = 5
Command1.Left = 9
Command1.Height = 24
Command1.Width = 75
Command1.Caption = "January"
Command1.TerminateRead = .T.
Command1.Name = "Command1"
Command2.Top = 29
Command2.Left = 9
Command2.Height = 24
Command2.Width = 75
Command2.Caption = "February"
Command2.Name = "Command2"
Command3.Top = 53
Command3.Left = 9
Command3.Height = 24
Command3.Width = 75
Command3.Caption = "March"
Command3.Name = "Command3"
Command4.Top = 77
Command4.Left = 9
Command4.Height = 24
Command4.Width = 75
Command4.Caption = "April"
Command4.Name = "Command4"
Command5.Top = 101
Command5.Left = 9
Command5.Height = 24
Command5.Width = 75
Command5.Caption = "May"
Command5.Name = "Command5"
Command6.Top = 125
Command6.Left = 9
Command6.Height = 24
Command6.Width = 75
Command6.Caption = "June"
Command6.Name = "Command6"
Command7.Top = 149
Command7.Left = 9
Command7.Height = 24
Command7.Width = 75
Command7.Caption = "July"
Command7.Name = "Command7"
Command8.Top = 173
Command8.Left = 9
Command8.Height = 24
Command8.Width = 75
Command8.Caption = "August"
Command8.Name = "Command8"
Command9.Top = 197
Command9.Left = 9
Command9.Height = 24
Command9.Width = 75
Command9.Caption = "September"
Command9.Name = "Command9"
Command10.Top = 221
Command10.Left = 9
Command10.Height = 24
Command10.Width = 75
Command10.Caption = "October"
Command10.Name = "Command10"
Command11.Top = 245
Command11.Left = 9
Command11.Height = 24
Command11.Width = 75
Command11.Caption = "November"
Command11.Name = "Command11"
Command12.Top = 269
Command12.Left = 9
Command12.Height = 24
Command12.Width = 75
Command12.Caption = "December"
Command12.Name = "Command12"
                                   A   %         P  +               U  $ 4   5     H#  C mo_paramb Dh  T C  ! T C \ . C mo_paramb N %       s C  The numeric parameter passed to # ABRMONTH is not between 1 and 12.   Function will return "***".  B *** ~! T  1988,CC  ZA ,015 rvalue = SUBSTR(CMONTH(DATE(&tmpdate)),1,3) + '.'
  2S C' Invalid parameter passed to ABRMONTH.   Function will return "***".  B ***  %  May. T  May 
 B  U  MO_PARAM CMONTH RVALUE POPERROR TMPDATE  %   b  %    N<  T       ^  T   C        z  T       U  THISFORM
 NWHATMONTH UMONTHRETURNTYPE URETURNVALUE ABRMNTH^  4   %C >  %   N:  T   N  W  T   C  U  ALPHA THISFORM UMONTHRETURNTYPE abrmnth,      Release     InitE    1 q    3  QD  2 A QA  3 FQ1 A  A 3 q !A  A 2                                   '   "     q  8    )                     
