Date, number & money functions
This group contains 11 functions covering both the wording and the arithmetic of Vietnamese construction paperwork: dates and times written out for acceptance records (Vietnamese, English or bilingual), lunar/solar calendar conversion, amounts spelled out in words, automatic quantity explanations built from cell formulas, linear interpolation and steel weight.
The examples below use a semicolon ; to separate arguments (Excel running on a Vietnamese regional format). If your Excel uses the English (US) format, type a comma , instead of ;.
Quick reference:
| Function | Purpose |
|---|---|
dvdLDate | Write a date as the sentence used in official records. |
dvdLTime | Write hours and minutes in words. |
dvdLTimeDate | Write time and date together in words. |
dvdLunarToSolar | Convert a lunar date into a solar date. |
dvdSolarToLunar | Convert a solar date into a lunar date. |
dvdVnd | Spell a Vietnamese dong amount out in words. |
dvdUsd | Spell a dollar amount out in English words. |
dvdExplain | Explain a formula as result = expression. |
dvdExplainE | Explain a formula as expression = result. |
dvdNoiSuy | One-dimensional linear interpolation. |
dvdSteelWeight | Steel weight from bar diameter and quantity. |
dvdLDate
Writes a date cell as the sentence used in official records, optionally prefixed with a place name.
Syntax:
=dvdLDate(shortDate; [Location]; [Language])| Parameter | Required | Description |
|---|---|---|
shortDate | Yes | Cell holding a date value. |
Location | No | Place name added in front of the sentence. |
Language | No | 0 = Vietnamese (default), 1 = English, 2 = bilingual. |
Example:
=dvdLDate(D6; "Hà Nội"; 0)
// → "Hà Nội, ngày 22 tháng 8 năm 2026"
=dvdLDate(D6; ; 2)
// → "ngày/date 22 tháng/month 8 năm/year 2026"Notes
- Passing an empty string
""asLocationproduces a dotted line to fill in by hand:...................., ngày 22 tháng 8 năm 2026. - An empty or zero date produces the blank template
ngày….......tháng….......năm…......, handy for forms that are signed later. - The day is always shown with two digits; January and February are shown as
01and02.
dvdLTime
Writes a time value as hours and minutes in words.
Syntax:
=dvdLTime(shortTime; [Language])| Parameter | Required | Description |
|---|---|---|
shortTime | Yes | Time value of type Date. |
Language | No | 0 = Vietnamese (default), 1 = English, 2 = bilingual. |
Example:
=dvdLTime(E6; 0)
// → "08 giờ 30 phút"
=dvdLTime(E6; 2)
// → "08 giờ/hours 30 phút/minutes"Notes
- An empty value produces the blank template
….......giờ….......phútfor forms filled in by hand.
dvdLTimeDate
Writes hours, minutes, day, month and year as one sentence — the opening line of an acceptance record.
Syntax:
=dvdLTimeDate(shortTime; shortDate; [Language])| Parameter | Required | Description |
|---|---|---|
shortTime | Yes | Time value of type Date. |
shortDate | Yes | Date value of type Date. |
Language | No | 0 = Vietnamese (default), 1 = English, 2 = bilingual. |
Example:
=dvdLTimeDate(E6; D6; 0)
// → "08 giờ 30 phút, ngày 22 tháng 8 năm 2026"dvdLunarToSolar
Converts a lunar date into the matching solar date.
Syntax:
=dvdLunarToSolar(shortDateLunar)| Parameter | Required | Description |
|---|---|---|
shortDateLunar | Yes | Lunar date, entered as a date value. |
Example:
=dvdLunarToSolar(DATE(2026;1;1))
// → 17/02/2026 (first day of Tết — the anchor for the holiday break in a programme)Notes
- The result is a date value: format the cell as Date to display it correctly.
- A lunar date that does not exist returns
#VALUE!. - The conversion uses Vietnam time (GMT+7).
dvdSolarToLunar
Converts a solar date into the matching lunar date.
Syntax:
=dvdSolarToLunar(shortDateSolar)| Parameter | Required | Description |
|---|---|---|
shortDateSolar | Yes | Solar date, entered as a date value. |
Example:
=dvdSolarToLunar(DATE(2026;8;22))
// → "10/07/2026 AL"Notes
- The result is text ending in
AL; a leap month is flagged in brackets, for example(6 N). - The conversion uses Vietnam time (GMT+7).
dvdVnd
Spells a Vietnamese dong amount out in words for the "in words" line of a payment certificate or contract.
Syntax:
=dvdVnd(Number; [match_mode])| Parameter | Required | Description |
|---|---|---|
Number | Yes | Cell holding the amount, or the amount typed directly. |
match_mode | No | 0 = words only (default), 1 = prefix the result with Bằng chữ: . |
Example:
=dvdVnd(125000000)
// → "Một trăm hai mươi lăm triệu đồng."
=dvdVnd(F42; 1)
// → "Bằng chữ: Một triệu, hai trăm năm mươi nghìn đồng."Notes
- The amount is rounded to whole dong before being spelled out; negative amounts are prefixed with "âm".
- An empty cell or a non-numeric value returns an empty string.
dvdUsd
Spells a dollar amount out in English words, for bilingual contracts and payment documents.
Syntax:
=dvdUsd(Number)| Parameter | Required | Description |
|---|---|---|
Number | Yes | Cell holding the amount, or the amount typed directly. |
Example:
=dvdUsd(5000)
// → "Five thousand dollars only"
=dvdUsd(1250.5)
// → "One thousand two hundred fifty dollars and fifty cents"Notes
- Zero returns
None; negative amounts are prefixed withMinus.
dvdExplain
Builds a quantity explanation for the cells of a range in the form result = expression, with every cell reference in the formula replaced by its actual value.
Syntax:
=dvdExplain(RangeToExplain; [HeaderRange]; [OptionValue]; [DecimalPlaces])| Parameter | Required | Description |
|---|---|---|
RangeToExplain | Yes | Range of cells to explain. |
HeaderRange | No | Header range; the matching header is written in front of each line. |
OptionValue | No | 1 = explain every cell (default), 0 = only cells that contain a formula. |
DecimalPlaces | No | Number of decimals in the result; -1 keeps the original formatting. |
Example:
=dvdExplain(F6; ; 0; 2)
// → "2.40=3*0.8" (F6 holds the formula =D6*E6 with D6 = 3 and E6 = 0.8)
=dvdExplain(F6:F20; $D$5:$F$5; 0; 2)
// → one line per formula cell, each prefixed with its column headerNotes
SUM(...)is expanded into a chain of additions andPRODUCT(...)into a chain of multiplications of the individual cells.- Multiple cells produce multiple lines separated by line breaks: turn on
Wrap Texton the formula cell to read them all. - The first argument must be a real cell or range reference on the sheet; passing an intermediate value returns an empty result.
dvdExplainE
Same as dvdExplain but written the other way round, expression = result, which suits the quantity statements of as-built documentation.
Syntax:
=dvdExplainE(RangeToExplain; [HeaderRange]; [OptionValue]; [DecimalPlaces])| Parameter | Required | Description |
|---|---|---|
RangeToExplain | Yes | Range of cells to explain. |
HeaderRange | No | Header range; the matching header is written in front of each line. |
OptionValue | No | 1 = explain every cell (default), 0 = only cells that contain a formula. |
DecimalPlaces | No | Number of decimals in the result; -1 keeps the original formatting. |
Example:
=dvdExplainE(F6; ; 0; 2)
// → "3*0.8=2.40"
=dvdExplainE(F6:F20; ; 0; 3)
// → "5+3.2+7.8=16.000" for a cell holding =SUM(...)Notes
- Every note for
dvdExplainapplies here too: real references are required, results span several lines, andSUM/PRODUCTare expanded.
dvdNoiSuy
One-dimensional linear interpolation between two known points — norms, haulage factors, excavation-depth factors.
Syntax:
=dvdNoiSuy(x1; x2; y1; y2; xnew)| Parameter | Required | Description |
|---|---|---|
x1 | Yes | Value x1. |
x2 | Yes | Value x2. |
y1 | Yes | Value y1 matching x1. |
y2 | Yes | Value y2 matching x2. |
xnew | Yes | Value of x to interpolate at. |
Example:
=dvdNoiSuy(5; 10; 120000; 150000; 7)
// → 132000 (haulage rate at a distance of 7 km)Notes
- When
x1equalsx2the function returns#DIV/0!.
dvdSteelWeight
Calculates steel weight from bar diameter and quantity.
Syntax:
=dvdSteelWeight(diameter; quantity)| Parameter | Required | Description |
|---|---|---|
diameter | Yes | Bar diameter, in mm. |
quantity | Yes | Number of bars for larger diameters, or the coil weight for small-diameter coiled steel. |
Example:
=dvdSteelWeight(16; 20)
// → 369.72 (kg — 20 bars of D16, 11.7 m each)
=dvdSteelWeight(8; 250)
// → 250 (kg — D8 coiled steel supplied by weight)Notes
- For diameters of 8 and below the function returns
quantityunchanged, because coiled steel is bought by weight. - Above diameter 8 the calculation assumes standard 11.7 m bars and a density of 7,850 kg/m³.