This is a discussion on Flash Tips & Tricks within the Flash Actionscript Programming forums, part of the Web Development category; Yeah that is there. Thanks posting the tips. And now Flash CS3 came. I will try to post new techniques ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#11
| |||
| |||
| Yeah that is there. Thanks posting the tips. And now Flash CS3 came. I will try to post new techniques in that. Keep on posting new techniques here. So that the people who wants to know flash tips, they can get it from one place instead of searching all over the web for a single tips. thanks ![]()
__________________ Karpagarajan. R Necessity is the mother of invention |
|
#12
| |||
| |||
| Hey All, I have one tip for flash people who works with action script and the data comes from server programming or server side xml. The tip is, Use "mx.controls.Alert.show()" instead of using "getURL("javascript:alert('');")" why because, the getURL function sometime fails to make alert, it will lead you to make false programming. Thanks -kb |
|
#13
| |||
| |||
| when we set number of text box or buttons or combo when we click tab it moves to next, for example if you have a clip in that order, tab does not work on the clip, for that you had to enable the tab to true. for example; clip1_mc.tabEnabled = true; then only tab works on the clip. |
|
#14
| |||
| |||
| In actionscript if we copy an array like the below code. After that we changed any one array it will change that two arrays. See the code Code: var original:Array = [ 1, 2, 3 ]; var copy:Array = original; copy[0] = 100; trace( original[0] ); // 100 trace( copy[0] ); // 100 Code: var original:Array = [ 1, 2, 3 ]; var copy:Array = [].concat( original ); copy[0] = 100; trace( original[0] ); // 1 trace( copy[0] ); // 100 Thanks |
|
#15
| |||
| |||
| This is the sample way to create a flash menu. HTML Code: import mx.controls.Menu;
import mx.controls.MenuBar;
import flash.net.FileReference;
var openListener:Object = new Object();
var fileRef:FileReference = new FileReference();
fileRef.addListener(openListener);
var my_mb:MenuBar;
var file_menu:Menu = my_mb.addMenu("File");
var edit_menu:Menu = my_mb.addMenu("Edit");
var view_menu:Menu = my_mb.addMenu("View");
var control_menu:Menu = my_mb.addMenu("Control");
var help_menu:Menu = my_mb.addMenu("Help");
file_menu.addMenuItem({label:"New Playlist", data:"Control+N", instanceName:"newInstance"});
file_menu.addMenuItem({label:"Open", instanceName:"openInstance"});
file_menu.addMenuItem({label:"Open URL", instanceName:"openUrlInstance"});
file_menu.addMenuItem({label:"Exit", instanceName:"exitInstance"});
view_menu.addMenuItem({label:"Full Screen", instanceName:"fullScreenInstance"});
view_menu.addMenuItem({label:"Half Size", instanceName:"halfSizeInstance"});
view_menu.addMenuItem({label:"Minimize", instanceName:"minimizeInstance"});
control_menu.addMenuItem({label:"Play", instanceName:"playInstance"});
control_menu.addMenuItem({label:"Pause", instanceName:"pauseInstance"});
control_menu.addMenuItem({label:"Next", instanceName:"nextInstance"});
control_menu.addMenuItem({label:"Previous", instanceName:"previousInstance"});
control_menu.addMenuItem({label:"Volume Up", instanceName:"volumeUpInstance"});
control_menu.addMenuItem({label:"Volume Down", instanceName:"volumeDownInstance"});
control_menu.addMenuItem({label:"Mute", instanceName:"muteInstance"});
help_menu.addMenuItem({label:" Help", instanceName:"helpInstance"});
help_menu.addMenuItem({label:"Shortcuts", instanceName:"keyBoardInstance"});
help_menu.addMenuItem({label:"About", instanceName:"aboutInstance"});
//Create listener object.
var mbListener:Object = new Object();
mbListener.change = function(evt_obj:Object)
{
var menuItem_obj:Object = evt_obj.menuItem;
switch (menuItem_obj.attributes.instanceName)
{
case "newInstance":
trace("New menu item");
break;
case "openInstance":
openFile();
trace("Open menu item");
break;
case "openUrlInstance":
trace("Open URL");
break;
case "exitInstance":
trace("Exit menu item");
fscommand("quit", "None");
break;
case "fullScreenInstance":
trace("fullScreenInstance");
fscommand("fullscreen", true);
break;
case "halfSizeInstance":
trace("halfSizeInstance");
fscommand("fullscreen", false);
break;
case "minimizeInstance":
trace("minimizeInstance");
break;
case "playInstance":
trace("playInstance");
break;
case "pauseInstance":
trace("pauseInstance");
break;
case "nextInstance":
trace("nextInstance");
break;
case "previousInstance":
trace("previousInstance");
break;
case "volumeUpInstance":
trace("volumeUpInstance");
break;
case "volumeDownInstance":
trace("volumeDownInstance");
break;
case "muteInstance":
trace("muteInstance");
break;
case "helpInstance":
trace("helpInstance");
break;
case "keyBoardInstance":
trace("keyBoardInstance");
break;
case "aboutPlayerInstance":
trace("aboutPlayerInstance");
break;
}
//trace(menuItem_obj);
};
//Add listener.
file_menu.addEventListener("change", mbListener);
view_menu.addEventListener("change", mbListener);
control_menu.addEventListener("change", mbListener);
help_menu.addEventListener("change", mbListener);
function openFile()
{
fileRef.browse();
openListener.onSelect = function(file1:FileReference):Void
{
trace("Opened " + file1.name);
};
}
__________________ S.Balasubramanian Nothing is impossible Last edited by Balasubramanian.S : 02-20-2008 at 01:04 AM. |
|
#16
| |||
| |||
| This is a simple way to create a right Click menu onClipEvent(load) { //MENU.customItems.push(Functioned2); MENU = new ContextMenu(); MENU.hideBuiltInItems(); Functioned = new ContextMenuItem("This movie is copyrighted by Your Company Name", doSomething); Functioned2 = new ContextMenuItem("Visite Our Website", doSomething2); MENU.customItems.push(Functioned); MENU.customItems.push(Functioned2); _root.menu = MENU; function doSomething() { } function doSomething2() { getURL("http://www.Discussweb.com", _blank); } }
__________________ S.Balasubramanian Nothing is impossible |
|
#17
| |||
| |||
| Hi, To Upload or Download a file using flash in web applications use "FileReference" class. The FileReference class provides a means to upload and download files between a user's computer and a server. An operating-system dialog box prompts the user to select a file to upload or a location for download. Each FileReference object refers to a single file on the user's hard disk and has properties that contain information about the file's size, type, name, creation date, modification date, and creator type (Macintosh only). FileReference instances are created in two ways: When you use the new operator with the FileReference constructor: var myFileReference = new FileReference(); When you call FileReferenceList.browse(), which creates an array of FileReference objects Thanks A.Ramesh |
|
#18
| |||
| |||
| Keyboard Keys and Key Code Values: Letters A to Z and standard numbers 0 to 9: HTML Code: Letter or number key, Key code, ASCII key code
A 65 65
B 66 66
C 67 67
D 68 68
E 69 69
F 70 70
G 71 71
H 72 72
I 73 73
J 74 74
K 75 75
L 76 76
M 77 77
N 78 78
O 79 79
P 80 80
Q 81 81
R 82 82
S 83 83
T 84 84
U 85 85
V 86 86
W 87 87
X 88 88
Y 89 89
Z 90 90
0 48 48
1 49 49
2 50 50
3 51 51
4 52 52
5 53 53
6 54 54
7 55 55
8 56 56
9 57 57
a 65 97
b 66 98
c 67 99
d 68 100
e 69 101
f 70 102
g 71 103
h 72 104
i 73 105
j 74 106
k 75 107
l 76 108
m 77 109
n 78 110
o 79 111
p 80 112
q 81 113
r 82 114
s 83 115
t 84 116
u 85 117
v 86 118
w 87 119
x 88 120
y 89 121
z 90 122 Last edited by aramesh : 02-18-2008 at 02:31 AM. |
|
#19
| |||
| |||
| How to download Flash object embeded in HTML Page? There are two ways to download the (.swf) file, 1. First we want to know the file name of .swf, we can get it by Right click the mouse View Source and Enter the key word .swf in find option. we can get the file name. Now, we can take this file from Temporary Internet Files folder in our system. While we visit or browse a site all file are stored in Temporary Internet Files, from this folder we can take all the files. 2. Second method is by using some swf catcher (like Sothink Swf Catcher) softwares we can download the file. By using these methods only ill download the Flash object. Regards A.Ramesh |
|
#20
| |||
| |||
| what is the other way of using Inheritance in flash? Other way of inheritance in AS1 is "prototype" and in AS2 its "interfaces" Regards A.Ramesh |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| C# .Net Tips & Tricks | oxygen | C# Programming | 85 | 01-08-2009 12:25 AM |
| SAP Tips & Tricks | leoraja8 | Operating Systems | 0 | 03-29-2008 12:11 AM |
| PHP Tips and Tricks | Sabari | PHP Programming | 20 | 12-18-2007 05:26 AM |
| .NET tricks & Tips | Karpagarajan | VB.NET Programming | 1 | 04-23-2007 08:17 AM |
| SEO Tips & Tricks | spid4r | Search Engine Optimization | 0 | 03-08-2007 11:03 PM |
Our Partners |