# Problem with paintapplication

**URL:** https://forum.kirupa.com/t/problem-with-paintapplication/237522
**Category:** flash
**Created:** [August 31, 2007, 12:41am UTC](https://forum.kirupa.com/t/problem-with-paintapplication/237522 "2007-08-31T00:41:45Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![krantzsimon](https://avatars.discourse-cdn.com/v4/letter/k/f08c70/32.png) [@krantzsimon](https://forum.kirupa.com/u/krantzsimon)
#### Post date: [August 31, 2007, 12:41am UTC](https://forum.kirupa.com/t/problem-with-paintapplication/237522/1 "2007-08-31T00:41:45Z")

</div>

Hi,

I have problem with a paint application, when I export the swf for Flash Player 6 it works correctly (see here: [[COLOR=#800080]http://www.preview.popnix.se/Player6.swf[/COLOR]](http://www.preview.popnix.se/Player6.swf)).

But when I export it for Flash Player 9 something will be wrong (see here: [[COLOR=#800080]http://www.preview.popnix.se/Player9.swf[/COLOR]](http://www.preview.popnix.se/Player9.swf)).

The actionscripts in the paintapplication is:

// If mouse button is pressed, set line style, start drawing.  
\_root.onMouseDown = function () {  
\_root.actions.pendown = true;  
with(\_root.drawingPlane){  
lineStyle( \_root.actions.thickness, \_root.actions.HEXcolor, \_root.actions.cA);  
moveTo(\_root.actions.lastX, \_root.actions.lastY);  
}  
}  
// If mouse button is released, stop drawing.  
\_root.onMouseUp = function () {  
\_root.actions.pendown = false;  
}  
stop();

AND also this:

onClipEvent(load){  
// Load default variables  
pendown = false;  
setting = false;  
thickness = 2;  
cR = 0;  
cG = 0;  
cB = 0;  
cA = 100;  
var HEXcolor;  
myColor = new Color(\_root.cBlock);  
}  
onClipEvent(enterFrame){  
lastX = x;  
lastY = y;  
X = \_root.\_xmouse;  
Y = \_root.\_ymouse;  
HEXcolor = (cR \<\< 16 | cG \<\< 8 | cB);  
if(pendown && !setting){  
\_root.drawingPlane.lineTo(X,Y); ;  
}  
myColor.setRGB(HEXcolor);  
\_root.cBlock.\_alpha = cA;  
}

Did anybody know what’s wrong? Need to find a solution asap…
