consider editing your post to include the contents of tempMenu.menu. Hard to tell what your problem is without seeing what the inputs are. Good luck.
–
shellterMay 18 '12 at 17:37

Thanks @shellter , I've found a solution using dialog instead of select. I'll update the question, or answer myself (not sure what is better to do) as soon as I'll have time to do it.
–
tmowMay 22 '12 at 14:19