This content has been marked as final. Show 9 replies
dropSh.inner = actiune.interioara;
dropSh.knockout = actiune.taie;
dropSh.hideObject = actiune.ascunde;
How can this bee ???? How can i fix this bug ? What am i doing wrong ?
What are dropSh and actiune?
var dropSh:DropShadowFilter = new DropShadowFilter(actiune.distanta, actiune.unghi, actiune.culoare_umbra, 50, actiune.blur, actiune.blur, actiune.cantitate, 3, !Inte, !Taie, !Ascunde);
dropSh is the DropShadowFilter and actiune is an object
I was wondering if actiune is a custom class (with a .as file?). It could be a datatype issue?
Not that the string value "false" is boolean true.
it's not a class its just an object
I tried do define another variable an got the same result
trace(test) //output is ok
//but on if statement is not ok
//output if test=false: yes
//output if test=true: yes
i even tried var test:Boolean=Boolean(actiune.interioara)
to make shore that actiune.interioara is boolean
How are you setting 'actiune.interioara'? What is the code for this part?
Are you sure you are getting the same result with 'var test:Boolean=Boolean(actiune.interioara)'
The reason I ask is that if you are casting the value to a Boolean, then the trace and if would show the same value (true:yes and false:no)
i am shore... i have checked it before an after 100 times
i solved the problem bu converting in to string if(String(actiune.interioara)=="true")
But i still don't understand why as boolean won't work
I think it is the way that 'actiune.interioara' is being set. Are you able to show how this value is being initialised?
Does this work too? : if(actiune.interioara=="true")
You can check the type of actiune.interioara by doing this:
trace(typeof(actiune.interioara)); // should trace Boolean if it is (I'm guessign it will trace String)