2 Replies Latest reply on Oct 12, 2007 11:00 AM by 791266

    exception in file reading

      I am writing some objects to a file using ObjectOutputStream. Initially some objects are written and then the output stream is closed. Then stream is opened and some more objects are written. This is done multiple times. Now while reading those objects with ObjectInputStream ( in a separate program ), I can only read those objects written ( before closing the output stream for the first time ) and not the remaining ones. I get the following exception

      - java.io.StreamCorruptedException: invalid type code: AC

      Please tell me what is the reason.