Skip to content
Loading
  • Rijwan Ansari
    +2
    Again you can format output as
    1. >> secs = 308  
    2. >> ts = TimeSerial(0, 0, secs)  
    3. >> WScript.Echo FormatDateTime(ts, vbLongTime)  
    4. >>  
    5. 00:05:08  
     
    +2
  • +2
    where you comparing the dates and where did you assign can u show me clearly
    +2
  • +2
    Thanks a lot working perfect 
     
    but  result like 2:49:00 AM  how to remove "AM"
    +2
  • +2
    if duration above 1 hour showing correctly like 01:44:00 like this
     
    if Duration below 1 hour.........    if 32 miutes  the showing 12:32:00 ouput should be like 00:32:00
    +2
  • Rajanikant Hawaldar
    +2
    try below, if you want to skip AM/PM you can try using "right"
    1. Date1 = alA_Filling(0)  
    2. Date2 = alA_Filling(1)  
    3. secValue = DateDiff("s",Date1,Date2)    
    4. ts = TimeSerial(0, 0, secValue)   
    5. Duration = FormatDateTime(ts, vbLongTime)  
     
    +2
  • +1
    ouput should be 
     
    HH:MM:SS
     
    and stored in variable 
    +1
  • +1
    unable to understand sorry
    +1