AddDays Function

public function AddDays(time1, step) result(time2)

Uses

Adds the specified number of days to the value of this instance.

Arguments

Type IntentOptional Attributes Name
type(DateTime), intent(in) :: time1
integer, intent(in) :: step

Return Value type(DateTime)


Contents

Source Code


Source Code

FUNCTION AddDays &
!
(time1, step) &
!
RESULT (time2)

USE Units, ONLY: &
! imported parameters:
day

IMPLICIT NONE

! Arguments with intent(in):
TYPE (DateTime), INTENT(IN) :: time1
INTEGER, INTENT(IN) :: step

! Local variables:
TYPE (DateTime):: time2
!------------end of declaration------------------------------------------------

time2 = AddSeconds (time1, INT(step * day) )
	
END FUNCTION AddDays