|
Paul,
Function named Fn_NextElevenMonths() as
given below, returns an array of the names of next eleven months following the
name of month supplied as an argument.
Sample db
named Funnction_NextElevenMonths_2K.zip, uploaded to Files
section of this group, demonstrates its implementation for populating the
text boxes as sought by you.
Best wishes,
A.D.Tejpal
===================================
Function Fn_NextElevenMonths(ByVal _
ThisMonthName As
String) As Variant
' Returns An Array of the names of next eleven months ' (following ThisMonthName). Dim MonthArray As Variant, Cnt As Long Dim MonthNum As Long, Ctr As Long ' Get MonthNum for This Month For Cnt = 1 To 12 If MonthName(Cnt, True) = Left(ThisMonthName, 3) Then MonthNum = Cnt Exit For End If Next ' Build the month array ReDim MonthArray(11) For Cnt = MonthNum + 1 To MonthNum + 11 Ctr = IIf(Cnt <= 12, Cnt, Cnt - 12) MonthArray(Cnt - MonthNum) = _ MonthName(Ctr, True) Next Fn_NextElevenMonths = MonthArray End Function
===================================
Please zip all files prior to uploading to Files section.
SPONSORED LINKS
YAHOO! GROUPS LINKS
|
- [AccessDevelopers] Autofill text boxes wartheit
- Re: [AccessDevelopers] Autofill text boxes A.D.Tejpal
- RE: [AccessDevelopers] Autofill text boxes Hoffman, Tobi K \(DYS\)
