DateTime.IsInPreviousNMinutes

This function checks if the specified datetime value dateTime falls within the number of minutes before the current date and time on the system. The function returns false if the dateTime value is wit...

Syntax

DateTime.IsInPreviousNMinutes(dateTime as any, minutes as number) as nullable logical

About

This function checks if the specified datetime value dateTime falls within the number of minutes before the current date and time on the system. The function returns false if the dateTime value is within the current minute. Parameters: - dateTime: The datetime or datetimezone value to be evaluated. - minutes: The number of minutes to check against.

Explanation

Verify if the time one minute before the current system time falls within the two minutes prior. Syntax: Power Query MDateTime.IsInPreviousNMinutes(DateTime.FixedLocalNow() - #duration(0, 0, 2, 0), 2) Result: true