Ejemplo n.º 1
0
 // Methods
 public bool IsInRange(MonthDate start, MonthDate end)
 {
     // Throw if the start is bigger that end
     if (start.Date > end.Date)
     {
         throw new Exception("The initial date is bigger that the end");
     }
     // Throw if the start is equals the end
     if (start.Date == end.Date)
     {
         throw new Exception("The initial date is equals the end");
     }
     // Return true if the current object date is between the range
     return(this.Date >= start.Date && this.Date <= end.Date);
 }
Ejemplo n.º 2
0
 public InsertExpenseForm(Utils.MonthDate month) : this()
 {
     this.month = month;
 }
Ejemplo n.º 3
0
 public bool Equals(MonthDate monthdate)
 {
     // Check if the year and the month ir equals
     return((this.Month == monthdate.Month) && (this.Year == monthdate.Year));
 }