Ask a Question related to Macromedia Director Lingo, Design and Development.
-
LukeWig #1
Re: formatting date
On 30/7/03 2:18 PM, in article bg7guu$b7j$1@forums.macromedia.com, "JemJam"
<webforumsuser@macromedia.com> wrote:
The systemDate object will give you the date in a fairly reliable format.> I need to display the current date as dd-mmm-yyyy. Can anyone give me a hand
> with this? The date functions in Lingo do not seem very straightforward.
> Thanks!
You can use this to display the date in whatever format you require. For
example
today = the systemDate
if today.day < 9 then dayStr = "0" & today.day
else dayStr =String(today.day)
-- month
MonthList = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug",\
"Sep", "Oct", "Nov", "Dec"]
monthStr = MonthList[today.month]
yearStr = string(today.year)
dateStr = dayStr & "-" & monthStr & "-" & yearStr
Hope this helps,
Luke
--------------------------------
| [url]www.meccamedialight.com.au[/url] |
| [url]www.lingoworkshop.com[/url] |
--------------------------------
LukeWig Guest
-
Date Formatting
Use the Day function. response.write day("12/1/2003") Of course, is that date the first of December, or the twelth of January? I suggest you... -
Date Formatting Error
I'm experiencing an anomaly with ColdFusion when formatting a string variable as a date at the moment Daylight Savings Time happens. I set a string... -
formatting date() and nbsp;
What I have is a date that I'd like to format to keep it together on one line using non-breaking spaces. I started with: date... -
Date - formatting
I'm needing to assign the following variable with the following data from the date. Does anyone have any help they could offer please? date_day =... -
Date Formatting Issue
I have Access 2000. On a form, I want to show (in an unbound text box) how long an agreement has been effect, and format it in years and days. ...



Reply With Quote

