set time in mm:ss only

jerry28ph

jerry
Local time
Yesterday, 16:54
Joined
Nov 16, 2008
Messages
141
Hi All,

Do we have an option in Table Design to format the time value in just "mm:ss" only, coz i cant find in design tab, may be there another way on access script to return the value in this format.
Any help is highly appreciated.

Thanks.
 
You shouldn't need to format in your table. Just format the Form/Report fields where you display the data.
 
Hi Rabbie,

Thanks you for the reply. I would like to take this opportunity to get some advise on my script. Im trying to save the value of Total Talk Time in my Tab_Summary. The field is Talk_CCEC and set as Text (i know it should be date/time but i just used it as Text for now because the table that Im getting all the records supplied by the server is set to "12:00:00 AM" and "hh" is supposed to eliminate). Anyways the tblSummary is just for reporting and not for computing so i think its ok to set it as Text. I tried it and I got the required format like "00:01:45" hours is not included.
But my problem with my SQL String is, I cant get the value "00:00:00" if the value of my subform is null. I want to save "00:00:00" in my Talk_CCEC field if the value of SumOfTime from my subform is null. Im stuck with this for 2 days now. Please help.

strSQL = "INSERT INTO tab_Summary (id_no, cs_datefrom, cs_dateto, pc_ext, pc_hunt, pc_name, in_ccec, in_totccec, in_int_ext, in_ext_caller, ttt_ccec, ttt_in_ext, ttt_ext_caller, out_all_calls, out_ttt) " & _
"VALUES ('" & Me.[Text135] & "', " & _
"'" & Me.[Text295] & "', " & _
"'" & Me.[Text297] & "', " & _
"'" & Me.[Text135] & "', " & _
"'" & Me.[Text133] & "', " & _
"'" & Me.[Combo17] & "', " & _
"'" & Me.[Smdr Qry_Total_CCEC (PC) subform].Form![Text2] & "', " & _
"'" & Me.[Sub_FrmTotalCCEC].Form![Text2] & "', " & _
"'" & Me.[Smdr Qry_Total_Direct subform1].Form![Text2] & "', " & _
"'" & Me.[Smdr Qry_Total_Queue subform].Form![Text2] & "', " & _
"'" & IIf(IsNull([Forms]![frmLog].[Query of Total Talk Time CCEC subform].Form![SumOfTime]), "00:00:00", [Forms]![frmLog]![Query of Total Talk Time CCEC subform].Form![Text2]) & "', " & _
"'" & Me.[Query of Total Talk Time (CCEC) - Direct subform].Form![Text2] & "', " & _
"'" & Me.[Query of Total Talk Time (CCEC) - Queue subform].Form![Text2] & "', " & _
"'" & Me.[Smdr Qry_Total_Outgoing subform].Form![Text8] & "', " & _
"'" & Me.[Query of Total Talk Time Outgoing Calls subform1].Form![Text2] & "');"
DoCmd.RunSQL strSQL

*****************

Please rabbie i really need to advise.
Thanks
Jerry


You shouldn't need to format in your table. Just format the Form/Report fields where you display the data.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom