You can extend FileBody, and extend "getContentType" to return what you
set with a new method "setContentType"
Christine
On Fri, 2008-10-31 at 09:06 +0100, Andreas Reichel wrote:
> Hi all,
>
> I've tried several hours without success to create a multipart, that has
> Content-Type: image/png.
> This code:
> --
> File file = File.createTempFile("chart", ".png");
> ImageIO.write(rendImage, "png", file);
> reqEntity.addPart("fileName", new FileBody(file));
> --
> always creates octet/stream, that the server does'nt recognize.
>
>
> Please would you give me a friendly hint or even a small example?
> I thank you in advance!
> Best regards!
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
--
dagdag is just a two character rotation of byebye
www.christine.nl
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]