I had been programming a system that takes inputs from user and saves them to the hard disk. I use ObjectWriter to write the whole serializable class. But Mac is not saving the data any more. The program is working fine on other systems. Can anyone help me please
the only modifications I made were introducing some JTextAreas and used BoxLayout at some places (I had been using GridLayout previously)
Code:
try
{
FileOutputStream fos = new FileOutputStream("saved.db");
GZIPOutputStream gzos = new GZIPOutputStream(fos);
ObjectOutputStream out = new ObjectOutputStream(gzos);
out.writeObject(this);
//WriteAllObjects(out);
out.flush();
gzos.flush();
fos.flush();
out.close();
gzos.close();
fos.close();
}
catch(Exception e)
{
//System.out.println(e);
ErrorPage(e);
}
the only modifications I made were introducing some JTextAreas and used BoxLayout at some places (I had been using GridLayout previously)