[Gambas-user] PDF file sent by gb.net.smtp

Benoit Minisini gambas at ...1...
Sat Apr 19 13:14:30 CEST 2008


On samedi 19 avril 2008, Leonardo Miliani wrote:
> Leonardo Miliani ha scritto:
> > Leonardo Miliani ha scritto:
> >> Leonardo Miliani ha scritto:
> >>> Benoit Minisini ha scritto:
> >>>> The first argument is the data, not the file path. You must write:
> >>>>
> >>>> PostService.Add(File.Load(FileChooser1.SelectedPath),
> >>>> "application/pdf", "document.pdf")
> >>>
> >>> I misunderstood the online help.... I'll try you suggestion.
> >>
> >> It doesn't work!
> >> I still continue to receive an empty document whose Mimetype is
> >> text/plain instead of application/pdf.
> >>
> >> The strange things are that my test applications runs for several
> >> seconds, as if it was sending the file and Thunderbird seems to download
> >> a big file, as it it had arrived without problems. But when I go to open
> >> the attachment I find the empty file.
> >> Any suggestions?
> >
> > Maybe I've found the problem. I've saved the email and opened it with a
> > Text editor.
> > Here is what I've found in it:
> >
> > "
> > [cut]
> > This is a MIME multipart message. Your mail reader isn't MIME capable.
> > You might not be able to read parts or all of this message.
> >
> >
> >
> > ------_=_libsmtp_Nextpart__000_000007DA.3B95D19_1
> > Content-Type: text/plain; name="MIME part #0"; charset="utf-8"
> > Content-Transfer-Encoding: quoted-printable
> >
> > Prova
> >
> >
> >
> > ------_=_libsmtp_Nextpart__000_000007DA.3B95D19_1
> > Content-Type: application/postscript; name="stampa.ps"
> > Content-Transfer-Encoding: base64
> > JSFQUy1BZG9iZS0xLjAKJSVCb3VuZGluZ0JveDogMCAwIDU5NCA4NDIKJSVDcmVhdG9yOiBRd
> >CAz
> > LjMuNwolJUNyZWF0aW9uRGF0ZTogZ2lvIGFwciAxNyAxMjozNjoyOCAyMDA4CiUlT3JpZW50Y
> >XRp
> > b246IFBvcnRyYWl0CiUlUGFnZXM6IDUKJSVEb2N1bWVudEZvbnRzOiBEZWphVnVTYW5zCgolJ
> >UVu
> > ZENvbW1lbnRzCiUlQmVnaW5Qcm9sb2cKJSBQcm9sb2cgY29weXJpZ2h0IDE5OTQtMjAwNSBUc
> >m9s
> > bHRlY2guIFlvdSBtYXkgY29weSB0aGlzIHByb2xvZyBpbiBhbnkgd2F5CiUgdGhhdCBpcyBka
> >XJl
> > Y3RseSByZWxhdGVkIHRvIHRoaXMgZG9jdW1lbnQuIEZvciBvdGhlciB1c2Ugb2YgdGhpcyBwc
> >m9s [cut]"
> >
> > You can see that the file has arrived as attachment but Thunderbird
> > isn't capable to separate it from the message body....
>
> I've tried to open my test message via webmail and I've got the same
> problems.
> Looking at the email that I've included in my previous message I think
> that it could be a bug in the gb.net.smtp component.
> In fact I think that the method used to include the message body
> (.Add()) isn't correct: it includes the message body as attachment.
> So the mail readers are not able to distinguish between the 2 Mimetypes
> (I think...).

This is strange, as I didn't have any problem with KMail...

Can you send me the mail as text file as you did. Just change the headers you 
don't want me to see, but I need that the data be as exact as possible to 
track the bug.

Thanks in advance.

Regards,

-- 
Benoit Minisini




More information about the User mailing list