BlockWrite failed!!!!?

In my application, I am using 'BlockWrite' procedure to write my structured data into file. It was working fine.

But since last 2-3 days, I am getting error in BlockWrite procedure.Actually, there are so many forms and units in my application; and i tried BlockWrite from different forms too, but in vain. I am stuck with the error and can not understand how it sudden refused to work!!!

I tried the same function with another testing application and it is working fine there; which is more confusing.

This is the testing function which I tried in both, my main application and my testing application.