Undesired text wrapping when sending email from VB

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • davidcm
    New Member
    • Jun 2007
    • 5

    Undesired text wrapping when sending email from VB

    Last week, I found some code on-line that allows me to send email via SMTP from my VB 6.0 application. I had to add the Winsock control to the project and add the code that performs the SendData requests and waits for the appropriate replies. The sending of the email seems to be working fine. But I am getting weird text wrapping within my first paragraph. I'm not sure why.

    For the text of the e-mail, I am using a String variable. I build it up dynamically, based on certain things that I want to insert into the e-mail, such as the name of a file and some simple identifier numbers from our app. I have a first paragaph, then I append a couple of control / line feed characters to the string, followed by the second paragraph. All of this is one String variable and then I send that as the text of the e-mail.

    When the e-mail is sent, the text is wrapping in the first paragraph at places I do not expect, not naturally. The first paragraph has two sentences and around 250 characters. The second paragraph, which has two sentences and around 150 characters, wraps naturally, as you would expect. Any ideas what might be wrong or how I can trouble-shoot?
  • Dököll
    Recognized Expert Top Contributor
    • Nov 2006
    • 2379

    #2
    Originally posted by davidcm
    Last week, I found some code on-line that allows me to send email via SMTP from my VB 6.0 application. I had to add the Winsock control to the project and add the code that performs the SendData requests and waits for the appropriate replies. The sending of the email seems to be working fine. But I am getting weird text wrapping within my first paragraph. I'm not sure why.

    Any ideas what might be wrong or how I can trouble-shoot?
    Greetings and welcome, davidcm!

    I hate to do this to you, but I was hoping you could add your code. Helps better get a handle on what you hope to achieve. How's that for a deal?

    Dököll
    Last edited by Dököll; Jun 27 '07, 04:15 AM. Reason: Text delete

    Comment

    • Killer42
      Recognized Expert Expert
      • Oct 2006
      • 8429

      #3
      Originally posted by Dököll
      I hate to do this to you, but I was hoping you could add your code...
      Yeah, I'd have to agree.

      Question, though - are you sure that the wrapping hasn't happened in the string, before sending it to e-mail?

      Comment

      Working...