# Simple if statement

**URL:** https://forum.kirupa.com/t/simple-if-statement/179334
**Category:** flash
**Created:** [February 18, 2006, 11:40pm UTC](https://forum.kirupa.com/t/simple-if-statement/179334 "2006-02-18T23:40:17Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![iMat](https://avatars.discourse-cdn.com/v4/letter/i/bbce88/32.png) [@iMat](https://forum.kirupa.com/u/iMat)
#### Post date: [February 18, 2006, 11:40pm UTC](https://forum.kirupa.com/t/simple-if-statement/179334/1 "2006-02-18T23:40:17Z")

</div>

[LEFT]I am using Flash 8, and for some reason, my if statement won’t work. I have a scrollbar which scrolls a movieclip (that contains AS loaded material (eg. attachmovie). I want it so that only when the material is longer than the scrollbar do I see the scroll bar.

For some reason, it doesn’t work. The traces don’t even work!

if (scrollbar.\_height \< menu\_mc.\_height) {  
scrollbar.\_alpha = 100;  
trace(“works”);  
}  
else {  
scrollbar.\_alpha = 0;  
trace(“not”)  
}  
[/LEFT]
