0

I am writing a code in which i am uploading multipart value with file, my code lines are below:

    final InputStream gpxInputStream = new ByteArrayInputStream(
                        RecordedRouteGPXFormatter.create(recordedGeoPoints).getBytes());
                final HttpClient httpClient = new DefaultHttpClient();

                final HttpPost request = new HttpPost(UPLOADSCRIPT_URL);

                // create the multipart request and add the parts to it

                final MultipartEntity requestEntity = new MultipartEntity();

                InputStreamBody isb = new InputStreamBody(gpxInputStream, "uploadedFile");

                requestEntity.addPart("uploadedFile",isb);

But at the line "requestEntity.addPart("uploadedFile",isb);" i am getting The type org.apache.james.mime4j.message.AbstractBody cannot be resolved. It is indirectly referenced from required .class files syntax error. please help me whats wrong with this.

1 Answer 1

1

have you add mime4j.xxx.jar to your lib folder? You can find it here

Sign up to request clarification or add additional context in comments.

1 Comment

Right Bro. Get the solution

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.