yanweiyuan3
2023-10-27 d1d15b61dfcf7fd0f800b32359f082cf580ed556
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Quintiq file version 2.0
#parent: #root
Method SetYearlyMonthAndDay (
  Number month_i,
  Number day_i
) id:Method_LibCal_dlgEvent_SetYearlyMonthAndDay
{
  #keys: '[131094.0.2102177363]'
  Body:
  [*
    ssYearlyMonth.Strings( Translations::Pattern_Months() );
    
    rowSeparator := ";";  // ssYearlyMonth.RowSeparator() in not possible (yet?) in WC.
    
    months := Translations::Pattern_Months().Tokenize( rowSeparator );
    month  := months.Element( month_i - 1 );
    day    := day_i.Format( "N(LPad0(2))" );
    
    ssYearlyMonth.Text( month );
    
    // Set the day of the month.
    this.SetYearlyDaysOfMonth( month );
    ssYearlyDayOfMonth.Text( day );
    
    // BUG: referencing the DropDownStringLists in methods GetDateOfFirstRecurrence and GetDateOfNextOccurrence
    //      results in an error in the TCE.
    // As a WORKAROUND, set the values also in a hidden label, and use that in those methods.
    lblYearlyMonth     .Text( month );
    lblYearlyDayOfMonth.Text( day   );
  *]
}