Printing GIF or any image file supported by printer and using Doc doc = new SimpleDoc(fin, DocFlavor.INPUT_STREAM.AUTOSENSE, null); the file is spooled successfully but the printer does not recognize the spooled data thus it fails to process and print it.