Salem,
I thought your code would work when i compiled it. It compiles but it doesnt do the job. I tried my program with turbo c's setvect and getvect, it worked, but it doesnt work with your code, although it looks like correct. I couldn't find out where the mistake is.