Digital Clock And Decompile
hi, i know that moderators are not so happy to talk about the subject of this 3d but,,,i beg your pardon... well i've browsed all the net for a long time to look for the source FLA of this digital clock(it's attached) but i couldn't help it. so i decided to install a decompiler. my need is just to change the color of sticks (black-->white) not much more. but,,,when i explort to flash the swf file and open it in mx2004 i get an error. otherways i can read the AS included in the swf but couldn't build the original flash from that! any help is welcome,,, bye!
FlashKit > Flash Help > Flash MX
Posted on: 12-21-2004, 02:39 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Mobile Phone Clock - Simple Digital 24 Hour Clock
Hi
I need to make a digital clock/watch for a mobile phone flash demo. I know there are lots of clock on flash kit but they all have seconds and minutes - I need just hours and minutes! - The clock also has to be 24 hour.
I've tried taking the code from a flash kit clock and tweaking it but it seems to screw up - for example 07.03 comes out as 7.3 - looks really naf like that!
If anyone can help me out with a source file or some code I would be most greatful!
Digital Clock
Pleas Help
How i can Build in Flash 4 Digital Clock
Thanks
Digital Clock
Hi everyone, I'm wondering if someone can point out a tutorial for a digital clock. I'm aiming to add a small clock, then the date after that.
Any help will be well appreciated
Many thanks
Simon
Digital Clock
i have created DIGITAL CLOCK for my desktop using actionscripting .......
NOW i wanna this file on desktop without MENU & default WINDOW ..... thats just the file with bg & time ......
how can i achieve it ?
[F8] CST Digital Clock
I need to make a Central Time Zone digital flash clock, but no tutorials I have found address how to make a clock specific to one time zone only, no matter what the user's local settings are. Can I please get some help?
Digital Clock Help
Hi all, I'm pretty new to flash, especially AS3, and have been asked to build a clock that does the following:
1 - Grabs the users computer time, and starts playing 12 hours back from that, at fast-forward speed.
2 - Fast-forwards over the course of approx. 30 secs to the current computer time, at which point it slows to normal clock speed.
So far, I have managed to adapt/write the following script, to produce a swf that gives me the current time, start time (12 hrs prior), and a counting time.
What I want to be able to do now, which I can't seem to work out, is to somehow tell the script to count from 12 hrs prior and stop on the current time.
Could anyone please help. Any suggestions would be so much appreciated! Thank you!
var count:Number = 0;
var maxNum:Number = 24;
var num:Number = 1;
var hourNum:Number = 1;
function increase(Event)
{
count += num;
clock();
}
function clock()
{
var dateate = new Date();
var hourStartZero:String = new String();
var minuteStartZero:String = new String();
var secondStartZero:String = new String();
var hourCurrentZero:String = new String();
var minuteCurrentZero:String = new String();
var secondCurrentZero:String = new String();
var hourCountZero:String = new String();
var minuteCountZero:String = new String();
var secondCountZero:String = new String();
var hourStart:Number = date.getHours() - 12;
var minuteStart:Number = date.getMinutes();
var secondStart:Number = date.getSeconds();
var hourCurrent:Number = date.getHours();
var minuteCurrent:Number = date.getMinutes();
var secondCurrent:Number = date.getSeconds();
var hourCount:Number = date.getHours();
var minuteCount:Number = date.getMinutes() + count;
var secondCount:Number = date.getSeconds();
if (secondStart < 10)
{
secondStartZero = "0";
}
else
{
secondStartZero = "";
}
if (minuteStart < 10)
{
minuteStartZero = "0";
}
else
{
minuteStartZero = "";
}
if (hourStart < 10)
{
hourStartZero = "0";
}
else
{
hourStartZero = "";
}
var displayStartTime:String = (hourStartZero + hourStart + ":" + minuteStartZero + minuteStart);
textStartBox.text = displayStartTime;
textStartBox.embedFonts = true;
if (secondCurrent < 10)
{
secondCurrentZero = "0";
}
else
{
secondCurrentZero = "";
}
if (minuteCurrent < 10)
{
minuteCurrentZero = "0";
}
else
{
minuteCurrentZero = "";
}
if (hourCurrent < 10)
{
hourCurrentZero = "0";
}
else
{
hourCurrentZero = "";
}
var displayCurrentTime:String = (hourCurrentZero + hourCurrent + ":" + minuteCurrentZero + minuteCurrent);
textCurrentBox.text = displayCurrentTime;
textCurrentBox.embedFonts = true;
if (secondCount < 10)
{
secondCountZero = "0";
}
else
{
secondCountZero = "";
}
if (minuteCount < 10)
{
minuteCountZero = "0";
}
else
{
minuteCountZero = "";
}
if (hourCount < 10)
{
hourCountZero = "0";
}
else
{
hourCountZero = "";
}
if (minuteCount >= 59) {
hourNum++;
num = 1;
count = 1;
minuteCountZero = "0";
var minuteCount:Number = 0;
}
hourCount = hourCount + hourNum;
if (hourCount == 24) {
hourCount = 0;
hourCountZero = "0";
hourNum = 1;
}
var displayCountTime:String = (hourCountZero + hourCount + ":" + minuteCountZero + minuteCount);
textCountBox.text = displayCountTime;
textCountBox.embedFonts = true;
}
stage.addEventListener(Event.ENTER_FRAME, increase);
Digital Clock
anbody know how to create a digital clock??
Kindly let me know
thanks in advance
Digital Clock
Hello where can i find tutorials on digital clocks using flash mx2004 or swish? and is this something hard to do?
Digital Clock
anbody know how to create a digital clock??
Kindly let me know
thanks in advance
Digital Clock
I made this digital clock using the gethour getminutes commands.
I have one question though. I also put in the getseconds command but I want it to update every second. The problem weith it is that once you open it ity will just show the same time.
Help Digital Clock - Am And Pm?
Im doing a world clock. I dont know how to make the 'ampm' thing. I tried to do it by making some variable - ampm and made my code tried to make it for example:
Quote:
if(hours>=24) {
hours=hours-24;
}
to become
Quote:
if(hours>=12) {
hours=hours-12;
}
if (hours>0&&hours<12) {
ampm="AM";
} else {
ampm="PM";
}
but maybe Im not doing it right cause the code doesnt work it shows me AM all the time. For now my clock works normally with 24 hour system - I mean 5:00 pm is 17:00. But I would like to make it in the way so it to look like 05:00pm. Do you know some tutorials for AM and PM specially?
For now its made in the following way:
Quote:
function UpdateClock(){
myDate = new Date();
hours = myDate.getUTCHours();
if(hours>=24) {
hours=hours-24;
}
minutes = myDate.getMinutes();
seconds = myDate.getSeconds();
sofia = myDate.getUTCHours()+2;
if(sofia>=24) {
sofia=sofia-24;
}
minutes = myDate.getMinutes();
seconds = myDate.getSeconds();
}
...
if (hours<10) {
hours = "0"+hours;
}
if (sofia<10) {
sofia = "0"+sofia;
}
Digital Clock
Hi Guys;
I'm Anita and just a bubbie according to Flash but everybody has to start somewhere. I made the digital clock with help of the video of Kirupa and it works PERFECTLY. Now I insert it inside my website and the only thing what is coming up is ":M". What did I done wrong? I put all the actions on 1 layer?!
_root.onEnterFrame = function() {
var myDateate = new Date();
var myHours = myDate.getHours();
var myMinutes = myDate.getMinutes();
var mySeconds = myDate.getSeconds();
var AmPm;
if (myHours < 12) {
AmPm = "AM";
}
else
{
AmPm = "PM";
}
if (myHours == 0){
myHours = 12;
}
if (myHours >12){
myHours = myHours - 12;
}
if (myHours <10) {
myHours = "0" + myHours;
}
if (myMinutes <10) {
myMinutes = "0" + myMinutes;
}
if (mySeconds <10) {
mySeconds = "0" + mySeconds;
}
time_txt.text = myHours + ":" + myMinutes + ":" + mySeconds + " " + AmPm;
}
this.Coffee_btn.onRelease=function(){
getUrl("coffee.html");
}
this.Food_btn.onRelease=function(){
getUrl("food products.html");
}
this.Cosmetics_btn.onRelease=function(){
getUrl("PC.html");
}
this.Earth_btn.onRelease=function(){
getUrl("PE.html");
}
this.Eximport_btn.onRelease=function(){
getUrl("exportimport.html");
}
Digital Clock
Hello where can i find tutorials on digital clocks using flash mx2004 or swish? and is this something hard to do?
Digital Clock
anbody know how to create a digital clock??
Kindly let me know
thanks in advance
Digital Clock
I am trying make a digital clock that displays a SWF for the coordinating number for the time, however I am running to a problem that it gets updated every iteration of the setInterval( ). So I am trying to have multiply watch( ) for each digit, which monitors any changes and if so it will update the SWF. The code below I am just trying to monitor the first character of seconds but I can’t seem to get that to work. Any suggestion? Thanks.
ActionScript Code:
this.createTextField("my_txt", 1, 100, 100, 800, 100);
function iterate()
{
var current:Date = new Date();
var seconds = current.getSeconds().toString();
if (seconds < 10)
seconds = "0"+seconds;
var firstDigit = seconds.charAt(0);
trace(firstDigit);
my_txt.text = seconds;
}
//
var myObject:Object = new Object();
myObject.tenssec = firstDigit;
var timeWatcher:Function = function(prop, oldVal, newVal){
if (newVal != oldVal) {
trace ("Time has elapse 10 secs");
//clear movieClip and loadMovie();
}
else
break;
return newVal;
}
myObject.watch("tenssec", timeWatcher)
setInterval(iterate,100);
Digital Clock - Please Help
Hi all, I'm pretty new to flash, especially AS3, and have been asked to build a clock that does the following:
1 - Grabs the users computer time, and starts playing 12 hours back from that, at fast-forward speed.
2 - Fast-forwards over the course of approx. 30 secs to the current computer time, at which point it slows to normal clock speed.
So far, I have managed to adapt/write the following script, to produce the swf (as attached), which gives me the current time, start time (12 hrs prior), and a counting time.
What I want to be able to do now, which I can't seem to work out, is to somehow tell the script to count from 12 hrs prior and stop on the current time.
Could anyone please help. Any suggestions would be so much appreciated! Thank you!
var count:Number = 0;
var maxNum:Number = 24;
var num:Number = 1;
var hourNum:Number = 1;
function increase(Event)
{
count += num;
clock();
}
function clock()
{
var date:Date = new Date();
var hourStartZero:String = new String();
var minuteStartZero:String = new String();
var secondStartZero:String = new String();
var hourCurrentZero:String = new String();
var minuteCurrentZero:String = new String();
var secondCurrentZero:String = new String();
var hourCountZero:String = new String();
var minuteCountZero:String = new String();
var secondCountZero:String = new String();
var hourStart:Number = date.getHours() - 12;
var minuteStart:Number = date.getMinutes();
var secondStart:Number = date.getSeconds();
var hourCurrent:Number = date.getHours();
var minuteCurrent:Number = date.getMinutes();
var secondCurrent:Number = date.getSeconds();
var hourCount:Number = date.getHours();
var minuteCount:Number = date.getMinutes() + count;
var secondCount:Number = date.getSeconds();
if (secondStart < 10)
{
secondStartZero = "0";
}
else
{
secondStartZero = "";
}
if (minuteStart < 10)
{
minuteStartZero = "0";
}
else
{
minuteStartZero = "";
}
if (hourStart < 10)
{
hourStartZero = "0";
}
else
{
hourStartZero = "";
}
var displayStartTime:String = (hourStartZero + hourStart + ":" + minuteStartZero + minuteStart);
textStartBox.text = displayStartTime;
textStartBox.embedFonts = true;
if (secondCurrent < 10)
{
secondCurrentZero = "0";
}
else
{
secondCurrentZero = "";
}
if (minuteCurrent < 10)
{
minuteCurrentZero = "0";
}
else
{
minuteCurrentZero = "";
}
if (hourCurrent < 10)
{
hourCurrentZero = "0";
}
else
{
hourCurrentZero = "";
}
var displayCurrentTime:String = (hourCurrentZero + hourCurrent + ":" + minuteCurrentZero + minuteCurrent);
textCurrentBox.text = displayCurrentTime;
textCurrentBox.embedFonts = true;
if (secondCount < 10)
{
secondCountZero = "0";
}
else
{
secondCountZero = "";
}
if (minuteCount < 10)
{
minuteCountZero = "0";
}
else
{
minuteCountZero = "";
}
if (hourCount < 10)
{
hourCountZero = "0";
}
else
{
hourCountZero = "";
}
if (minuteCount >= 59) {
hourNum++;
num = 1;
count = 1;
minuteCountZero = "0";
var minuteCount:Number = 0;
}
hourCount = hourCount + hourNum;
if (hourCount == 24) {
hourCount = 0;
hourCountZero = "0";
hourNum = 1;
}
var displayCountTime:String = (hourCountZero + hourCount + ":" + minuteCountZero + minuteCount);
textCountBox.text = displayCountTime;
textCountBox.embedFonts = true;
}
stage.addEventListener(Event.ENTER_FRAME, increase);
Digital World Clock - Help Plz
Hi there.
Can someone help me what i should do with this script so that i can run 2 cocks with a different time zone (Miami EST TIME & Frankfurt, EUROPE TIME).
I can find a lot of tutorials on Flashkit.com but all those are too complex and they have an analog script included.
IF someone can help that'd be awsome.
Dave
---
1st keyframe:
myDate = new Date();
dateTextField = (mydate.gethours()+":"+myDate.getMinutes()+":"+myd ate.getSeconds());
if (myDate.getMinutes() < 10) {
dateTextField = (mydate.gethours()+":0"+myDate.getMinutes()+":"+my date.getSeconds());
}
if (myDate.getSeconds() < 10) {
dateTextField = (mydate.gethours()+":"+myDate.getMinutes()+":0"+my date.getSeconds());
}
if ((myDate.getMinutes() < 10) && (myDate.getSeconds() < 10)) {
dateTextField = (mydate.gethours()+":0"+myDate.getMinutes()+":0"+m ydate.getSeconds());
}
---
2nd frame
gotoandplay(1);
}
Digital Clock Question.?
http://www.systemdark.com/academy/fl...ock/clock.php#
i am followin this to a T and its not working at all . anyone can help as to why not this is not working... help..
Simple Digital Clock
I have a digital clock in my movie and every time it's midnight it displays all zeros like this 00:00:00 am. How do I make sure that when it is midnight it displays like this: 12:00:00 am
BTW I'm somewhat a beginner in actionscripting.
This is what I have right now. Please let me know how to modify this piece
My_Hours = SysDate.getHours();
if (My_Hours >=12) {
My_Hours = My_Hours - 12;
AM_PM = "PM";
} else {
AM_PM = "AM";
}
if (length(My_Hours)<2) {
My_Hours = "0" add My_Hours;
}
Thanks a lot!
Flash Digital Clock
I'm new to flash BTW [_flashDumb.iWould = say], I made a clock based on the tutorial by Adrian Wherry
http://www.flashkit.com/tutorials/Ac...-591/more1.php
(Thank you very much Adrian). And I want to make something different.
I just want to show one element of time, say...... seconds. I modified the dynamic text to show just 2 digits (:00):
// Script to get the time string from the newDate object
newDate = new Date();
mySecond = newDate.getSeconds();
// If the hour display is less than 2 digits, add an extra 0
if (length(mySecond)<2)
{
mySecond = "0" + mySecond;
}
// Space out the HH:MM:SS
displayTime = mySecond+ ":";
......the second frame in the tute has the same except an additional line of gotoFrame(1);
I tried modifying the AS took out the parts where.... hr, and min are called/used/coded..... whathaveyou..... And I'm left with what I think will do what I want. Low an behold, it ain't working.
I know there's more or less to that...... Any ideas?
P.S.: Also I wanted to make individual dynamic texts, say if I wanted to show the hr, and min in different colours or shades, sizes, etc. ......[copy+paste & replace the variable on the dynm. text?]
Digital Clock And Date
hey i need to create a digital clock and date function in flash mx 2004 for the web, does anyone have a tutorial for it?
PST Time Digital Clock
I'm trying to put a script together to display PST time (GMT -8 hours) and I thought I'd nailed it on the head by using:
Code:
hour = (timedate.getUTCHours()-8);
until this morning when I realised that anything before 8am GMT was showing negative time in PST, ie 10pm would say -2 hours, which is obviously rubbish.....
The code I've been using is:
Code:
onClipEvent (enterFrame) {
hour = (timedate.getUTCHours()-8);
minutes = timedate.getMinutes();
seconds = timedate.getSeconds();
todaydate = timedate.getDate();
day = timedate.getDay();
dayname = days[day];
month = timedate.getMonth()+1;
year = timedate.getFullYear();
if (Length(minutes)==1) {
minutes = "0" + minutes;
}
if (Length(seconds)==1) {
seconds = "0" + seconds;
}
currenttime = hour + ":" + minutes + ":" + seconds;
currentdate = todaydate + "/" + month + "/" + year;
delete timedate;
timedate = new Date();
}
can anyone shed any light on this? Cheers
Digital Clock Tutorial Help
hello there,
well its my first post and if any mistakes are made by me then lemme know
ok, i was doing a tutorial on making a digital clock which shows the time and the date as well, here is the link to that tutorial
link to the tut
ok i completed the tutorial without any problems, but the result was not correct
my result, showed the time and the date for a second and then it just disappeares
can anyone tell me where can i posibly be going wrong?
or are there any glitches in the above tutorial?
thank you very much for your time
Digital World Clock
Hi there,
Can anyone point me to a .fla of a digital world clock which calculates and displays the times in different cities (including Daylight Saving)?
I've found a simple digital clock which gets the time from the system clock and ive found an analogue world clock but am not able to combine them into a digitial world clock.
Many thanks
N
Digital Clock In Flash Using AS2.0
Hi folks,
Greetings for the day!! well my client wants a digital clocks to shown all at once. the details are as below:
There should be eight different clocks. Each clock should display time in different time zone. The time zones are for the cities – New York, London, Paris, Johannesburg, Moscow, Singapore, Sydney and Tokyo.
All the clocks should be displaying time simultaneously.
Please also keep in mind of the Day light saving.
i'm able to do this using by getting local time from my system and by changing the values by +hrs or -hrs depending on GMT time but my question is what iff the user changes the system time??? can any one give me a solution. my code looks as below:
onClipEvent (load) {
days = new Array('Sunday','Monday','Tuesday','Wednesday','thu rsday','Friday','Saturday','Sunday');
months = new Array('January','February','march','April','May',' June','July','August','September','October','Novem ber','December');
timedate = new Date();
}
onClipEvent (enterFrame) {
hour = timedate.getHours();
minutes = timedate.getMinutes();
seconds = timedate.getSeconds();
todaydate = timedate.getDate();
day = timedate.getDay();
dayname = days[day];
month = timedate.getMonth();
monthname = months[month];
year = timedate.getFullYear();
if (Length(minutes)==1) {
minutes = "0" + minutes;
}
if (Length(seconds)==1) {
seconds = "0" + seconds;
}
newdelhi = hour + ":" + minutes + ":" + seconds;
johannesberg =
delete timedate;
timedate = new Date();
}
which i've placed on a movie clip
hope a quick response.
thanks all
srini
Speeding Up A Digital Clock.
I am trying to speed up a digital clock. Right now I have a digital clock that is going off the system clock, but if I do that I can't speed it up. I would like the clock to go through 8 hours of time in 8 minutes. I also have to have it done in code so I could change it to 10 hours in 10 minutes or 4 hours in 4 minutes, etc... Please help me someone.
Simple.Digital.Clock
I am the beginner.I was looking some basic .fla files and found "Simple Digital Clock".I downloaded it (here is the link page: http://www.actionscript.org/resource...ock/Page1.html)
I wanted to do my digital clock but it didn't work.I doubted myself and copy + paste same codes on my new .fla file but it didn't work.
I haven't understood what's wrong.Something is changed with copy + paste in Flash ?
by the way,i am using Flash CS3 and i am always opening Actionscript 2.0 file
Digital Clock Code...
I have found the following code for creating a digital clock in AS3...
ActionScript Code:
// Create new TextField variable
var textBox:TextField = new TextField();
// Add the TextField to the stage
addChild(textBox);
// Create function that performs enterframe tasks
function refreshTimes(Event)
{
/*
Please note that these tasks
are done constantly in order
to have an up to date time.
In As2, the date updated itself,
whereas in As3, you must recreate
the Date var consistantly
*/
// Make new Date variable
var date:Date = new Date();
// Variables that add a 0 to seconds and minutes under 10
var hourZero:String = new String();
var minuteZero:String = new String();
var secondZero:String = new String();
// Retreave dates for hours seconds and minutes
// Turn dates into Number variables
var h:Number = date.getHours();
var m:Number = date.getMinutes();
var s:Number = date.getSeconds();
// Checks seconds/minutes and adds 0 if under 10
if (s < 10)
{
secondZero = "0";
}
else
{
secondZero = "";
}
if (m < 10)
{
minuteZero = "0";
}
else
{
minuteZero = "";
}
if (h < 10)
{
hourZero = "0";
}
else
{
hourZero = "";
}
// Create variable to store hours minutes and seconds combined
var displayTime:String = (hourZero + h + ":" + minuteZero + m + ":" + secondZero + s);
// Display the time String on the stage
textBox.text = displayTime;
}
//Performs the above function every frame
stage.addEventListener(Event.ENTER_FRAME, refreshTimes);
This is from newGrounds however I am trying to find a way of accomplishing the same thing WITHOUT having to update using an ENTER_FRAME listener...
Anyone have any ideas...
Digital Clock In Flash 8
I have been trying to put a digital clock into my Flash 8 websites for I don't know how long. I have read dozens of tutorials, watched videos, and read books but no matter what Action Script I write, it doesn't work. The latest script returned "_level0.inst" when I tested the movie. The variable is named correctly and I followed the steps from a video tutorial where it worked perfectly for them. Do I have some setting that is messing it up? Here is the code:
Attach Code
onClipEvent (enterFrame) {
myTime = new Date ();
Seconds = myTime.getSeconds();
Minutes = myTime.getMinutes ();
Hours = myTime.getHours();
if (Hours>=12) {
ampm = "pm";
} else {
ampm = "am";
}
if (Hours>=13) {
Hours = Hours-12;
}
if (length(Minutes) == 1) {
Minutes = "0"+Minutes;
}
if(length(Seconds) == 1) {
nSeconds = "0"+nSeconds;
}
Clock = Hours+":"+Minutes+":"+Seconds+ " "+ampm;
}
Digital Clock In Flash 8
I have been trying to put a digital clock into my Flash 8 websites for I don't know how long. I have read dozens of tutorials, watched videos, and read books but no matter what Action Script I write, it doesn't work. The latest script returned "_level0.inst" when I tested the movie. The variable is named correctly and I followed the steps from a video tutorial where it worked perfectly for them. Do I have some setting that is messing it up? Here is the code:
Attach Code
onClipEvent (enterFrame) {
myTime = new Date ();
Seconds = myTime.getSeconds();
Minutes = myTime.getMinutes ();
Hours = myTime.getHours();
if (Hours>=12) {
ampm = "pm";
} else {
ampm = "am";
}
if (Hours>=13) {
Hours = Hours-12;
}
if (length(Minutes) == 1) {
Minutes = "0"+Minutes;
}
if(length(Seconds) == 1) {
nSeconds = "0"+nSeconds;
}
Clock = Hours+":"+Minutes+":"+Seconds+ " "+ampm;
}
Digital Clock Without Font?
anyone know if its possible to make a digital clock, in flash, with images as numbers instead of using a font? if not then recommend a tutorial on how to make your own font, lol.
Digital Clock UK Timings
Sir,
I am working as a Web Designer and presently i am working on one Project where i have to put a Digital Clock of UK. I designed the Digital clock with summer time (Present is Summer season) but when winter comes it should show the winter time .
I am not able to write the script. Can you help me?
I want the clock should show the winter and summer time according to the season changes.
Thanking you,
Yours sincerely,
Chitra Ramgire
Digital Clock Tutorial
I have done exaclty the same as the tutorial on the digital clock, and when i publish or play it, the screen is blank!.. i have a fair knowledge of flash!..the script is 100% ... is there anything missing from tutorial ?
Digital Clock For More Countries
Hello all,
I want to know about digital clock for more countries. when i mouseOver to a country then it should show the time of that that country.
How I can do this.
Please suggest me.
Countrywise Digital Clock
Hello all,
I want to know about countrywise digital clock. I have a map and when I mouseOver on a country then it should show the time of that that country.
like when i over on india then it should show the indian time
and when i over on china then it should show the chinies time....
How I can do this.
Please suggest me.
Countrywise Digital Clock
Hello all,
I want to know about countrywise digital clock. I have a map and when I mouseOver on a country then it should show the time of that that country.
like when i over on india then it should show the indian time
and when i over on china then it should show the chinies time....
How I can do this.
Please suggest me.
Countrywise Digital Clock
Hello all,
I want to know about countrywise digital clock. I have a map and when I mouseOver on a country then it should show the time of that that country.
like when i over on india then it should show the indian time
and when i over on china then it should show the chinies time....
How I can do this.
Please suggest me.
Custom Digital Clock
Hi Guys and Gals,
I'm wondering if anyone knows the technique used to create this clock
http://billychasen.com/clock/
I need to do something similar with a clock I'm making not images like in the human clock but movieclips.
It would be fantastic if someone could help me in my search.
Thanks.
Problem In Digital Clock...
hi, i've got problem here.... yesterday i've done a digital clock.its really cool.BUT, there's a problem when i apply my digital clock in my flash website (fully in flash -- not HTML, not PHP or etc.). when i click another page of the site, (only clocking when i open my flash site file) the clock was stop.why this happen and could someone help me to fix it up.
here my AS:
Code:
_root.onEnterFrame = function(){
var myDate:Date = new Date();
var myHours = myDate.getHours();
var myMinutes = myDate.getMinutes();
var mySeconds = myDate.getSeconds();
var AmPm;
if (myHours < 12){
AmPm = "AM";
}
else
{
AmPm = "PM";
}
if (myHours == 0) {
myHours = 12;
}
if (myHours > 12) {
myHours = myHours - 12;
}
if (myHours < 10) {
myHours = "0" + myHours;
}
if (myMinutes < 10) {
myMinutes = "0" + myMinutes;
}
if (mySeconds < 10) {
mySeconds = "0" + mySeconds;
}
time_txt.text = myHours + ":" + myMinutes + ":" + mySeconds + " " + AmPm;
}
Digital Clock Tweaks
Hi,
I used J.E. aka IamNot Jubba's Digital Clock tutorial to create 4 different world clocks. I tweaked his code to make each clock 24-hour (military time), then I offset each clock for 4 different locations (+0 hours for SF, +7 hours for UK, +9 for SA, +3 for NYC). Check out the code for SA:
onClipEvent (enterFrame) {
myTime = new Date();
nSeconds = myTime.getSeconds();
nMinutes = myTime.getMinutes();
nHours = myTime.getHours() + 9;
if (length(nMinutes) == 1) {
nMinutes = "0"+nMinutes;
}
if (length(nSeconds) == 1) {
nSeconds = "0"+nSeconds;
}
nTime = nHours+":"+nMinutes+":"+nSeconds;
}
My question is how to adjust the code so the hours don't "break" after 23:00 hours (11pm in regular time). For example if it's 4:00pm in South Africa, my clock incorrectly displays 31:00- it should read 16:00. I tried adding this line but no go:
if (nHours>=23) {
nHours = nHours-9;
}
Any math/flash geniouses out there wanna take crack at this? I'd really appreciate any help.
Thanks!
tcg
Digital World Clock - HELP ME PLZ
Hi there.
Can someone help me what i should do with this script so that i can run 2 cocks with a different time zone (Miami EST TIME & Frankfurt, EUROPE TIME).
I can find a lot of tutorials on Flashkit.com but all those are too complex and they have an analog script included.
IF someone can help that'd be awsome.
Dave
---
1st keyframe:
myDate = new Date();
dateTextField = (mydate.gethours()+":"+myDate.getMinutes()+":"+myd ate.getSeconds());
if (myDate.getMinutes() < 10) {
dateTextField = (mydate.gethours()+":0"+myDate.getMinutes()+":"+my date.getSeconds());
}
if (myDate.getSeconds() < 10) {
dateTextField = (mydate.gethours()+":"+myDate.getMinutes()+":0"+my date.getSeconds());
}
if ((myDate.getMinutes() < 10) && (myDate.getSeconds() < 10)) {
dateTextField = (mydate.gethours()+":0"+myDate.getMinutes()+":0"+m ydate.getSeconds());
}
---
2nd frame
gotoandplay(1);
}
The Digital Clock Tutorial
Its wrong.. The tutorial clock is wrong.. Check it out here.. http://www.kirupa.com/developer/acti...ital_clock.asp The am pm thing doesn't work..when its a time after 12 oclcok the clock says its "am" and when its b4 12 is also says "am". Is there anyway to fix this becasue i need the:
if (hours<12) {
}
script too work.. at the moment it does what ever is in the if space.. not the else.. WHY??
Clock (digital Time)
hello all, I was wondering if anyone knows how to make a digital display clock that is in 12 hour format and to target 1 specific time zone? is this at all possible?
thank you
Building Digital Clock
I know this has been a zillion times but I can only get this to partialy work.
What is happening is instead of it sayin 11:32 (this is AM) it says
-1:32
Here is my code
Code:
onClipEvent (enterFrame) {
myTime = new Date();
nSeconds = myTime.getSeconds();
nMinutes = myTime.getMinutes();
nHours = myTime.getHours();
if (hours>=12) {
ampm = "pm";
} else {
ampm = "am";
}
if (hours>=13) {
nHours = nHours-12;
}
if (length(nMinutes) == 1) {
nMinutes = "0"+nMinutes;
}
if (length(nSeconds) == 1) {
nSeconds = "0"+nSeconds;
}
nTime = nHours+":"+nMinutes+":"+nSeconds+" "+ampm;
}
Also I hate that I had to write this on my MC instead of my main timeline however it was the onkly way I could get it to work so if you know how to fix this I would also appreciate it.
Thanks,
tmo
Digital Clock Woes
Hello. I use Flash 8.
I have some code here for anyone who knows flash. My problem is its not working. My background is white and the clock text is red. I have numbers and letters and punctuation stuff embedded.
The clock doesnt show up tho. Does it have something to do with framerate of the swf? Im really clueless to why this is not working.
Its dynamic text with the variable named clock. Thanks if you can help.
onClipEvent (enterFrame) {
myTime = new Date();
Seconds = myTime.getSeconds();
Minutes = myTime.getMinutes();
Hours = myTime.getHours();
if (Hours>=12) {
ampm = "pm";
} else {
ampm = "am";
}
if (Hours>=13) {
Hours = Hours-12;
}
if (length(Minutes) == 1) {
Minutes = "0"+Minutes;
}
if (length(Seconds) ==1){
nSeconds = "0"+nSeconds;
}
Clock = Hours+":"+Minutes+":"+Seconds+" "+ampm;
}
Digital Clock Not Working?(tutorial)
I downloaded digital clock tutorial on site did exact as guidence.
but can't figure out what wrong with or i mess up with something?
please help.
thanks,
bhushan
FlashMX________________Time & Date? Digital Clock
Hey there... I've just finished the kirupa digital clock forum found here...
http://www.kirupa.com/developer/actionscript/digital_clock.htm
and there may be a few problems with the source.
1) First problem is when the time shows the single digit minutes as 10:8:37am instead of :08.
2) The second is that it still seems to show am, instead of pm.
3) Third (and last) is that although the action script looks like it show/read as NON-24 hour time... it still reads like 13:8:24
I understand it is getting the time & date from my computer, but my date & time are fine.
Any idea of how to fix this or know of another digital flash clock tutorial? Possible one that recieve the information from a server and not from a users computer?
Thanks
B
|