how u can import BASE64Encode() package i am getting error please help me
Welcome to the Java Programming Forums
The professional, friendly Java community. 21,500 members and growing!
The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.
>> REGISTER NOW TO START POSTING
Members have full access to the forums. Advertisements are removed for registered users.
how u can import BASE64Encode() package i am getting error please help me
File newFile=new File("C:\\Image\\9R6-CCI\\09082010\\K08E091209FT_8033.tif");
byte[] fileData = new byte[ (int)newFile.length()];
InputStream inStream = new FileInputStream( newFile);
inStream.read(fileData);
inStream.close();
String tempFileData = new String(fileData);
String imageString=new BASE64Encoder().encode(fileData);
i am working on final year project please tell me which package or which jar i will include in that code .
in this above code error"BASE64Encoder cannot be resolved to a type" what i can i do for removing that
error please tell me thanks in advance
Please don't hijack a 3 year old post, especially with a seemingly unrelated question. And please don't double post...I have merged your posts
For someone who is at "final year" level, your question is pretty depressing. On topic however, the BASE64 classes you're trying to use are long-removed from the Java API. I advise you to use an Apache Commons API instead, see Base64 or if you're really against using libraries, have a look at DataTypeConverter.
Please use [highlight=Java]//code goes here...[/highlight] tags when posting your code
k
thanks