Sending Mail using SMTP


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: Sending Mail using SMTP

  1. #1
    Philip Guest

    Sending Mail using SMTP


    Hi,

    I am trying to send mail using the SMTP protocol. Everything works fine.
    But if I add an attachment, the attachment is displayed as text and not as
    an attachment file. I am using UUEncode to encode the attachment.

    I have a similar component in VB6 which works perfectly. When porting it
    to VB.Net it gives this error. I have a feeling that It has to do with the
    ASCII/UNICODE encoding. In VB6, strings are by default in Unicode. However
    it seems that in VB.Net strings are in Ascii and converting them to Unicode
    dosent seem to work properly (or may be i am wrong).

    Another observation, the mail size (with attachment) when sent using VB6
    is almost double that of the the mail size (with attachment) when sent using
    VB.Net

    Could someone pl help

    regards
    Philip

  2. #2
    Phil Weber Guest

    Re: Sending Mail using SMTP

    > I have a similar component in VB6 which works perfectly.
    > When porting it to VB.NET it gives this error.


    Philip: What error?

    > I have a feeling that It has to do with the ASCII/UNICODE
    > encoding. In VB6, strings are by default in Unicode. However
    > it seems that in VB.NET strings are in Ascii and converting
    > them to Unicode doesn't seem to work properly (or maybe
    > I am wrong).


    You are. ;-) Strings are Unicode by default in VB.NET.
    ---
    Phil Weber



  3. #3
    Phil Weber Guest

    Re: Sending Mail using SMTP

    > I am trying to send mail using the SMTP protocol. Everything
    > works fine. But if I add an attachment, the attachment is
    > displayed as text and not as an attachment file. I am using
    > UUEncode to encode the attachment.


    Philip: See if you find this example helpful:
    http://www.harrisonlogic.com/HL/Code/sendmailaspnet.asp
    ---
    Phil Weber



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center