# Code works in for Flash 6 but not 7

**URL:** <https://forum.kirupa.com/t/code-works-in-for-flash-6-but-not-7/174507>\
**Category:** flash\
**Created:** [January 6, 2006, 8:29am UTC](https://forum.kirupa.com/t/code-works-in-for-flash-6-but-not-7/174507 "2006-01-06T08:29:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sigepmest37](https://avatars.discourse-cdn.com/v4/letter/s/8491ac/32.png) [@sigepmest37](https://forum.kirupa.com/u/sigepmest37)\
**Post date:** [January 6, 2006, 8:29am UTC](https://forum.kirupa.com/t/code-works-in-for-flash-6-but-not-7/174507/1 "2006-01-06T08:29:44Z")

</div>

```auto
this.onEnterFrame = function() {
 i = i+1;
 clip = this.createEmptyMovieClip("eqbar"+i, i);
 this.clip._x = 0;
 this.clip._y = 0;
 with (this.clip) {
  lineStyle(1, 0xCCCCCC, 20);
  for (var j = 0; j<10; j++) {
   z = int(Math.random()*8+5);
   beginFill(0x222222, 30);
   moveto((j*6), 0);
   lineto((j*6), (0-z));
   lineto((3+j*6), (0-z));
   lineto((3+j*6), 0);
   lineto((i*6), 0);
   endFill();
  }
  if (i == 3) {
   i = 0;
  }
 }
};

```

This code works fine when published in Flash6. However, when I publish in Flash 7 I don’t see anything. Any ideas?
