Solved

Date & Time Split Error

  • 16 March 2023
  • 1 reply
  • 100 views

Badge

i Split Date and time 

but its shows wrong time 

=Right('0'+CStr(Hour([AMClockTran.StartTime])),2)+':'+Right('0'+CStr(Minute([AMClockTran.StartTime])),2)

icon

Best answer by sweta68 16 March 2023, 12:18

View original

1 reply

Userlevel 7
Badge +10

 Hi @tahirsiddiqui190 ,

I have used same formula in GI and It shows time in 24 hours format, If you want to display it in 12 Hours format, You can use below formula.

=IIF(HOUR([AMBomItem.CreatedDateTime])<=12,PADLEFT(CSTR(HOUR([AMBomItem.CreatedDateTime])),2,'0')+':'+PADLEFT(CSTR(MINUTE([AMBomItem.CreatedDateTime])),2,'0')+ ' AM',PADLEFT(CSTR(HOUR([AMBomItem.CreatedDateTime])-12),2,'0')+':'+PADLEFT(CSTR(MINUTE([AMBomItem.CreatedDateTime])),2,'0')+ ' PM')

Below is our result using the above formula. 

Note: Just use required field instead of AMBomItem.CreatedDateTime.

Hope, This helps!

Regards

Sweta

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved