B beelze69 Active Member Licensed User Longtime User Feb 3, 2022 #1 Hi, I intend to get the date in the format YYYY-MM-DD only. In my B4a Code, I use , DateTime.DateFormat="yyyy-MM-dd" Log(DateUtils.TicksToString( DateUtils.SetDate( year,month,day))) {Where year, month and day are all values that I pass through some function(say) } However, the output that is displayed in the log for a date say 03rd February,2022 is 2022-02-03 00:00:00 How do I ensure that the Hour, Minute, Second is not shown ? Thanks
Hi, I intend to get the date in the format YYYY-MM-DD only. In my B4a Code, I use , DateTime.DateFormat="yyyy-MM-dd" Log(DateUtils.TicksToString( DateUtils.SetDate( year,month,day))) {Where year, month and day are all values that I pass through some function(say) } However, the output that is displayed in the log for a date say 03rd February,2022 is 2022-02-03 00:00:00 How do I ensure that the Hour, Minute, Second is not shown ? Thanks
Erel B4X founder Staff member Licensed User Longtime User Feb 3, 2022 #2 Please use [code]code here...[/code] tags when posting code. Use DateTime.Date instead of DateUtils.TickToString. Upvote 0
Please use [code]code here...[/code] tags when posting code. Use DateTime.Date instead of DateUtils.TickToString.
B beelze69 Active Member Licensed User Longtime User Feb 3, 2022 #3 Erel said: Please use [code]code here...[/code] tags when posting code. Use DateTime.Date instead of DateUtils.TickToString. Click to expand... Thanks Erel Upvote 0
Erel said: Please use [code]code here...[/code] tags when posting code. Use DateTime.Date instead of DateUtils.TickToString. Click to expand... Thanks Erel