[Beta] DateTime - A flash date/time extension

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • This was just a little investigation after being asked about converting timestamps in flash to a date/time format.

    Please login to see this link.

    It's basically a very thin wrapper around the Date object provided in the standard library. The date/time is initialised to the current date/time, and allows you to set/get the time using UTC or local date/time values.

    Hopefully the object is straight forward enough. If you have any suggestions questions or comments feel free to ask.

  • For people with existing projects the TimeStamp object is available in Flash:

    Please login to see this link.

    There will be minor differences with the native version (timezone handling during DST, can't remember what else) but that's the legacy of not having developed them together :)

  • Thanks for this object, i have have found a strange bug with the DateTime object though.

    If i try to get the "Local timezone offset from UTC in seconds" then it selects/moves to another window i have open and has locked MMF2 up on the expressions dialog and i need to force close it with task manager.

    All the other expressions seem to work fine.

  • Thanks for this object, i have have found a strange bug with the DateTime object though.

    If i try to get the "Local timezone offset from UTC in seconds" then it selects/moves to another window i have open and has locked MMF2 up on the expressions dialog and i need to force close it with task manager.

    All the other expressions seem to work fine.

    This bug has now been fixed. Get the latest from Please login to see this link.

    I'm currently in the process of porting this extension to Android. I need to finish writing the string expressions before I can release it for testing.

  • Does not seem to be working :(

    This is my code (using PC runtime, have yet to test on Android):

    Upon pressing Space Bar
    > Set local month to 1
    > Set local year to 2012
    > Set local date to 8

    Always
    >Set alterable string to Str$(LocalDayMonth( "DateTime" ))+"/"+Str$(LocalMonth( "DateTime" ))+"/"+Str$(LocalYear( "DateTime" ))

    This always displays 0/0/0...

    Please login to see this link.
    Please login to see this link.

  • I'm finding it a bit difficult to save Millisecond timestamp data. As I believe there are 13 digits in Millisecond Unix Time, any container I place it in (string, counter, etc) expresses it like so:

    1.341945835608E12

    I have found that to solve this for normal Unix Timestamp data, I must perform this conversion:
    Round(UNIXTimestamp( "DateTime" ))
    And it displays properly (1341945835, for example). If I do not "Round" the timestamp, I get this: 1.341945835E9

    But trying to Round a Millisecond Unix Timestamp comes out like this:
    2147483647
    Instead of how it should, like so:
    1341945835608

    Any tips on ways to save/load this data in easy strings or numbers?
    I know I can String Parse the 1.341945835608E12 to remove the "." and "E12", but if there is another way I'd like to know it :)

    Please login to see this link.
    Please login to see this link.

  • I am not sure exactly what causes this. Presumably it's a default property of the toString method to format numbers of this length in this way. I could add a method which gives you the digits as a string if you like, though I think that this is more fundamental to MMF, since I am not actually responsible for making that string conversion.

    Are you using the Android version or the Flash version?

  • If you're using Str$() at any point, try FloatToString$(). MMF has details on that in its help file.

    Darkwire Software Lead Programmer (C++ & C#)
    Please login to see this link. | Please login to see this link. | Please login to see this link. | Please login to see this link.

  • So I have found that "Set Date/Time with timestamp in seconds" or "...milliseconds" does not change any of the LocalTime values. They only seem to update with "Set Date/Time to Now."

    (using the Android version)

    Please login to see this link.
    Please login to see this link.

  • For those of you who are testing the HTML5 beta, I have ported the DateTime flash extension to Html5. Please login to see this link. You will probably need to follow the steps outlined in the extension sdk documentation for adding new extensions to the runtime. I hope that the process will be a bit more dynamic in future so that beta extensions are more accessible (i.e. no code required).

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!