Thanks for the code man, at least i have an idea of what to do. I guess I'll be studying C step by step instead of asking questions like that . Thanks to you all.