Hi
This is about getting date dynamically and displaying on the swf using objects.
Create a Dynamic Text Field on a key frame
Give it an instance name
Open the actions panel for that keyframe where you kept the dynamic field.Type in the below code:
var myDate_date:Date;
myDate_date = new Date();
myTextField_txt.text = myDate_date.getDate();
Publish it and you will get the today's date on the swf.
Regards,
Muthaiah Thiagarajan
http://www.fmass.in/
I am a Principal Web Technologist with EMC Corporation,Bangalore.Welcome to my blog.I have initiated this blog to share my knowledge with respect to flash,photoshop,asp.net,sharepoint services, illustrator, HTML , CSS, Javascript and few other design softwares.
Wednesday, January 16, 2008
Using Objects - To get Date
Create a Dynamic
var myDate_date:Date;
myDate_date = new Date();
myTextField_txt.text = myDate_date.getDate();
Tuesday, January 15, 2008
Flash Tips - Drawing with Pointer on the stage
Hi,
It's a simple technique to create a pencil tool on the stage to draw live, on the swf file in the browser.
Create a blank .fla file
Select the first key frame of layer 1 on the timeline
Press F9 key, You will get the action layer
Paste this code on the Actions pane:
_root.onMouseMove = function()
{
_root.lineStyle(1, 0xFF0000, 100);
_root.lineTo(_root._xmouse, _root._ymouse);
updateAfterEvent();
};
Publish the file as swf and html.
View it on the browser.
Regards,
Muthaiah Thiagarajan
http://www.fmass.in/
It's a simple technique to create a pencil tool on the stage to draw live, on the swf file in the browser.
Create a blank .fla file
Select the first key frame of layer 1 on the timeline
Press F9 key, You will get the action layer
Paste this code on the Actions pane:
_root.onMouseMove = function()
{
_root.lineStyle(1, 0xFF0000, 100);
_root.lineTo(_root._xmouse, _root._ymouse);
updateAfterEvent();
};
Publish the file as swf and html.
View it on the browser.
Regards,
Muthaiah Thiagarajan
http://www.fmass.in/
Subscribe to:
Posts (Atom)