|Subject:||Re: TIdMultiPartFormDataStream.AddFile and unicode FileName|
|Posted by:||Remy Lebeau (Indy Team) (email@example.com)|
|Date:||Mon, 25 Sep 2006|
"Dorin Marcoci" <marcod…@matrix.md> wrote in message
> I have some troubles adding a file with unicode file name.
> AddField have this declaration:
Indy does not support Unicode at all. You will not be able to do what you
are asking for.
> Is there another way to do this (without change indy implementation)?
> Like to add a stream?
You can add a file stream manually (call TIdMultipartFormDataStream's
Fields.Add() method and then fill in the details of the TIdFormDataField
object manually). But you will have to expose access to
TIdMultipartFormDataStream's protected FSize member first so that you can
increment it with your custom stream size. Also, the filename itself will
still be stored and transmited as Ansi instead of Unicode, so providing your
own stream from a unicode filename will not be very useful as the server
will still receive a converted filename that may be wrong.
TIdMultiPartFormDataStream.AddFile and unicode FileName posted by Dorin Marcoci on Sun, 24 Sep 2006