2 Replies Latest reply on Dec 1, 2006 1:54 AM by Flash2KoolForSkool

    _global _root variable problems

      I am creating an interactive whiteboard which uses action script to trace the useers mouse movements and draw a line. Which works perfectly, the line coulour is set using a variable which is initialised at the beginning of the code:

      if (count != true){
      _global.linesize = 6;
      _global.linecolour = 0x000000;
      _global.line = false;

      count = true;

      However in order to allow the user to change the colour of their lines, i have created a simple bit of code which changes the value of the _global.linecolour variable to Red for example (0xFF0000).

      _global.linecolour = 0xFF0000;

      *Please do not comment on the use of (press) instead of (release) it is meant to be that way*

      The variable is being changed, but for some reason the change does not affect the code on the timeline.

      The code on the timeline and on the button is as follows: