B4A Tutorial [B4X] DateUtils - Simplifies Date and Time Calculations - Erel    
Feb 7, 2021   
(10 reactions)DateUtils is a code module with a set of useful date and time related methods.
It complements DateTime api, it doesn't replace it.
The methods included in DateUtils:
'Calculates the period...
link: Fixed....
link: B4A IDE (13.4) lists DateUtils and StringUtils as 10.0 (Online). Link clicking shows the correct...
link:
DateUtils - Simplifies Date and Time Calcuations
12 years later - fixed.
Why a big jump to...
B4i Question DateUtils - GetMonthName set device localization language - Alexander Stolte    
Dec 22, 2021if i call DateUtils.GetMonthName then it returns the month name in english on a german language device, how can i set the device language to get the month name in the right language?...
link: ----------------
SetDateTimeLocale(GetPreferredLanguage)
Log(DateUtils.GetMonthName(DateTime.Now))
End Sub
Sub...
B4i Library [module] DateUtils - Erel    
Nov 6, 2014   
(6 reactions)B4i implementation of DateUtils: http://www.b4x.com/android/forum/threads/26290/#content...
link: I created a dateAdd function using the date.addperiod...
link: You should use DateUtils.AddPeriod....
link: The date utility does not have a DateAdd function...
B4A Question [B4X] DateUtils.SetDateAndTime with pm - Alexander Stolte    
Jan 18, 2024I live in a country that has the 24 time format. How do people in the USA use the DateUtils.SetDateAndTime function? You can't specify whether the time I create is am or pm....
link: :mm:ss a"
Log(DateUtils.SetDateAndTime(2024,1,18,13,59,0)) '1705604340000
Log...
B4i Question DateUtils SetDate - Cannot parse: invalid date - Alexander Stolte    
Jan 12, 2024
if i do this and call the DateUtils.SetDate function, the following error occurs:
Application_Start...
link: )
Me.As(NativeObject).GetField("_dateutils").SetField("_ad", "")
End Sub...
B4i Question >[SOLVED] XUI Dateutils locale - astronald    
Jan 9, 2021Hello how i can locale for IOS
i try this code
Dim days As List = DateUtils.GetDaysNames
Works perfect in B4A
but in b4i only get english days
Thanks...
link: test:
SetDateTimeLocale ("es_ES")
Sub SetDateTimeLocale (locale As String)
Dim loc As ...
link: How i can get default IOS language?
Sub GetPreferredLanguage As String
Dim no As NativeObject...
link: Thanks very much Oparra, this work for me.
105855
last question:
How i can get default IOS language...
B4i Question DateUtils - Balasubramanian (first post)    
Jun 24, 2025
Dim newDate As Long = d + DayOffset * DateTime.TicksPerDay
This code is wrong, assuming that you ...
link:
Dim newDate As Long = d + DayOffset * DateTime.TicksPerDay
This code is wrong, assuming that you w...
link: (1)
Dim year As Int = parts(2)
d = DateUtils.SetDate(year, month, day)
End Try...
link: -2025")
Dim Period1 As Period
Period1.Days = 405
Dim Date2 As Long = DateUtils.AddPeriod(Date1...
Bug? DateUtils - Crash when 24-Hour time turned off - Andrew (Digitwell)    
May 20, 2019)
calrng.RangeStart = DateUtils.SetDate(yr,mt,dy)
This code works perfectly if in
Settings ->...
link: Great. Thanks...
link: Is it possible to set the locale on iOS programmatically?
Yes: https://www.b4x.com/android/forum/thr...
link: A bit more information,
If I set the phones region to US then all is fine.
I also found this: http...
B4i Question DateUtils.SetDate not incrementing for 26th Oct 2025 - emexes (first post)    
Feb 2, 2025
DateUtils.AddPeriod works!!
R.I.P. the fact of "24 hours in a day" 🫣
(presumably using p.Hours = 24 will resurrect your original problem)...
link: Great stuff - DateUtils.AddPeriod works!! Thanks a lot!!...
link: Using DateUtils.AddPeriod is the correct solution....
link: Instead of using ticks values associated with time 00:00 of the date, use ticks value with time 12:0...
B4i Question DateUtils Issue [Solved] - Descartex    
Jun 19, 2017Hi.
When I try to run this:
Dim MonthsToShow As Int
Log(DateUtils.PeriodBetween(DateTime.DateParse(ToDate),DateTime.DateParse(FromDate)).Months)
MonthsToShow=DateUtils...
link: I've downloaded again de DateUtils Module and it worked at first time...
Must be something...
link: I've sent you an email.
Thanks a lot....
link: Can you upload the project (File - Export as zip)?...
Page: 1  
2  
3  
4