For future reference, please include the details of the problem in your post rather than in your code.

You never write anything to your file...the Map is appended to the StringBuffer, but you need...