I want to make a function call and send either a string or an integer ...
function getImage(val:*):void{ if(val == String){ switch(val){ case'next': loadNext(); break; case'prev': loadPrev(); break } }else{ loadImg(val); } }
and changes my function accordingly ... does anyone know how to determine the type of parameter?
Thanks -J
source share