ComponentOne True DBInput Pro 8.0
InRange Method (TDBDateX)

 

Reference> TDBDateX Object> TDBDateX Object Methods> InRange Method (TDBDateX)

InRange Method (TDBDateX)

You can use the InRange method to determine whether a specific date value is within an appropriate range. This is very effective when working with dates for range checking to determine various conditions.

Syntax

object.InRange ([Date], StartDate, EndDate)

Arguments

date is an optional Variant (Date) value for range checking. If not specified, the date set in the Value property will be applied.

startdate, enddate are required Variants (Dates: two date times you want to use to set a range.)

Return Value

True if the date is in range, False otherwise.

Remarks

If the year part for date, startdate and enddate  is omitted, InRange uses the current year from your system date.

If the date part for date, startdate, or enddate is omitted, the date serial will be set to 0, which equals to Dec. 30, 1899. If the time part is omitted, the time serial will be also set to 0, which equals to 00:00:00.

If either date, startdate, or enddate is set to Null, this method returns False. If date is not specified, the date set in the Value property will be applied for the underlying value.

See Also

Compare Method (TDBDateX)

Match Method (TDBDateX)

 

 


Copyright (c) GrapeCity, inc. All rights reserved.

Product Support Forum  |  Documentation Feedback