Hi guys,
I have a problem with my program. I tried to make a simple program to download pdf file from internet. First, I tried to use it for downloading text and html file, it works well. but, it didn't work with pdf file. the program could produce output file, but it can't be opened.
Here is the code snippet:
java.io.BufferedInp
java.io.FileOutputS
java.io.BufferedOut
byte data[] = new byte[1024];
while(in.read(
{
bout.write(data)
}
bout.close()
in.close();
Anyone could give me the clue? BTW, is there any website that provide free java library, especially one that support file operation (download, upload, etc)?
Thanks in advance.
Java Official Group is created for the following topics: Java 2 Enterprise Edition - J2EE, Java 2 Standard Edition - J2SE, Java 2 Micro Edition - J2ME, XML, XSL, XSD, XPATH, Web Services, Jini, JXTA for all type of Java Geeks.
Whoever posts spam / ads / job related message will be BANNED IMMEDIATELY
No comments:
Post a Comment