Create a Whiteboard or Blackboard
Learn how to create a Whiteboard or Blackboard that the user can draw with whist online. It is very surprisingly easy to create a Whiteboard / Blackboard and the file size is tiny. When you print it will print whatever you drawn on your board. It is that much more difficult to add different colours and brush size
Step One: Setting Up the Document
Go to: File > New > General Tab > Flash Document > OK (Ctrl N)
You are now ready to customise the document. Go to: Modify > Document (Ctrl J)
Type in the dimensions that you want for your Movie. Mine is: 300 x 125 px (pixels)
If you want a Blackboard change the: Background Color
For Frame Rate type: 30 fps
Step Two: ActionScript - Timeline
If the Timeline is closed, open it: Window > Timeline (Ctrl Alt T)
Select: Frame 1
If the Actions Panel is closed open it: Window > Actions (F9)
In the Actions Panel if Script Assist is on, Switch: Script Assist Off
Type (or Copy & Paste) the following Actionscript into Actions Panel:
_root.createEmptyMovieClip("myLine", 0);
_root.onMouseDown = function() {
myLine.moveTo(_xmouse, _ymouse);
myLine.lineStyle(2, 0xff0000, 100);
_root.onMouseMove = function() {
myLine.lineTo(_xmouse, _ymouse);
}
}
_root.onMouseUp = function() {
_root.onMouseMove = noLine;
}
Check the Syntax by clicking the Check Syntax button:
Turn the Actions panel off: Window > Actions (F9)
You are ready to Test the movie. Go to: Control > Test Movie
Close your Test Window:
Step Three: Placing the Delete Button on Stage
Go to: Window > Common Libraries > Buttons
Scroll down until you can see folder: Classic Buttons
Double click to open the folder:
Scroll down until you can see folder: Ovals
Double click to open the folder:
Drag on Stage the: Blue Oval Button
Step Four: Delete Button ActionScript
Select the: Blue Button
If the Actions Panel is closed open it: Window > Actions (F9)
Type (or copy and paste) the following Actionscript into Actions Box:
on (release) {
myLine.clear();
}
Go to: Control > Test Movie