ComponentOne True DBInput Pro 8.0
CalcValue Method (TDBDTCalcX)

 

Reference> TDBDTCalcX Object> TDBDTCalcX Object Methods> CalcValue Method (TDBDTCalcX)

CalcValue Method (TDBDTCalcX)

You can use the CalcValue method to add or subtract a specified time interval from the internal amount of dates. By default, the underlying value will be set to 0 when the object is first created. To initialize the value during calculation, call the InitValue method.

Syntax

object.CalcValueValue, [Interval]

Arguments

value is a required numeric expression that is the number of interval of time you want to add or subtract. It can be positive (to get dates in the future) or negative (to get dates in the past)

interval is an optional constant that determines the interval of time you want to add or subtract.

The interval argument has these settings:

0

Days (Default)

1

Months

2

Years

3

Seconds

4

Minutes

5

Hours

Return Value

None

Remarks

The days that make up one month is determined by the DaysPerMonth property and the hours that make up one day can be specified by the HoursPerDay property.

Whenever calling the CalcValue method, the internal results for the amount of dates will be applied to the Years, Months, Days, Hours, Minutes, Seconds properties. You can also retrieve the totals for the individual intervals by calling the GetTotals method.

See Also

InitValue Method (TDBDTCalcX)

 

 


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

Product Support Forum  |  Documentation Feedback