But the function that you have told is a win32 API, right?
That will not work in DOS mode. I mean in DOS OS.
I was looking for something that will work under DOS mode, some solution in C or even in assembly language.