cDateTime: AddMonths

AddMonths

Adds a specified number of months to the current date, returning a new cDateTime instance with the calcuated value.



 Public Function AddMonths(
	  ByVal Months As Long ) As cDateTime

Parameters

Months
[ByVal] Long. The number of months to be added.

Return Values

cDateTime -  The new cDateTime instance containing the calculated value.

Remarks

If the new month does not have as many days in it as the original month, then the day is set to the last day of the new month if it exceeds the maximum number of days for the new month.

See Also

Project VBCorLib Overview Class cDateTime Overview cDateTime Properties cDateTime Methods AddMinutes AddSeconds