Converts a text time to a serial number for a time, a number from 0 (12:00:00 AM) to 0.999988426 (11:59:59 PM). Format the number with a time format after entering the formula.
Name | Type | Description |
arg1 | number | Is a text string that gives a time in any one of the Microsoft Excel time formats (date information in the string is ignored). |
builder.CreateFile("xlsx"); const oWorksheet = Api.GetActiveSheet(); var oFunction = Api.GetWorksheetFunction(); var ans = oFunction.TIMEVALUE("11/5/18 11:17:00 am"); oWorksheet.GetRange("C1").SetValue(ans); builder.SaveFile("xlsx", "TIMEVALUE.xlsx"); builder.CloseFile();