Halsafar, reduce your test case to as little code as possible (where it still crashes) and post that. Also make sure you're using the modern version (<fstream>), not the old one (<fstream.h>).
All the buzzt CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.