19/05/2023: A causa di un errore sono stati cancellati, insieme ad account creati da bot, alcuni account legittimi. Si prega di leggere qui: https://www.gambas-it.org/smf/index.php?topic=9733.0
https://gitlab.com/gambas/gambas/commit/3418ce77f35d79f999d76c3884c9076ac3cdae4a
Public Sub Main() Select Case Sgn(System.TimeZone) Case -1 Print Date.ToRFC822(Now, "+0" & CStr(Abs(System.TimeZone) / 3600) & "00") Case +1 Print Date.ToRFC822(Now, "-0" & CStr(Abs(System.TimeZone) / 3600) & "00") Case 0 Print Date.ToRFC822(Now) End Select 'Print Date.FromRFC822(Date.ToRFC822(Now, "+0" & CStr(Abs(System.TimeZone) / 3600) & "00"))End
Public Sub Main() Dim s As String Dim i As Integer i = Abs(System.TimeZone / 3600) If Len(CStr(i)) = 1 Then s = "0" & CStr(i) & "00" Else s = CStr(i) & "00" Endif Select Case Sgn(System.TimeZone) Case -1 Print Date.ToRFC822(Now, "+" & s) Case +1 Print Date.ToRFC822(Now, "-" & s) Case 0 Print Date.ToRFC822(Now) End SelectEnd