|
#1
|
|||
|
|||
How to calculate build time
I created these build time events
Application.Macros(vbldTemporary).Add "START_TIME", vbld_FormatTime() Application.Macros(vbldTemporary).Add "START_TIME_EX", vbld_FormatDateEx(now,"hh:MM:SS") Application.Macros(vbldTemporary).Add "END_TIME", vbld_FormatTime() Application.Macros(vbldTemporary).Add "END_TIME_EX", vbld_FormatDateEx(now,"hh:MM:SS") (_EX means that this is expression that i print in the log) How can i calculate the build time? |
#2
|
|||
|
|||
There is a property on the build object with the build start time:
http://www.kinook.com/VisBuildPro/Ma...meproperty.htm And to calculate: Code:
sec = DateDiff("s", Builder.StartTime, Now) hr = Int(sec / 3600) sec = sec - hr * 3600 min = Int(sec / 60) sec = Int(sec Mod 60) ' format in hh:mm:ss format strElapsed = vbld_PadLeft(CStr(hr), 2, "0") & ":" & _ vbld_PadLeft(CStr(min), 2, "0") & ":" & vbld_PadLeft(CStr(sec), 2, "0") |
#3
|
|||
|
|||
reply
if i will follow your approach, how can substring 'Builder.StartTime' and 'Now' to take only the time without the date
i.e: 1/9/2012 17:16:36 --> 17:16:36 (i want to save the start and end time in a variable) Thanks |
#4
|
|||
|
|||
|
|