Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Format a line in Outlook message

Format a line in Outlook message

Scheduled Pinned Locked Moved Visual Basic
question
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    RichardBerry
    wrote on last edited by
    #1

    Hi I'm using the following code to create an outlook mail message, but need to bold and undeline certain lines in the message body. How can I do this? Dim oOutlook As New Outlook.Application Dim oMailitem As Outlook.MailItem oMailitem = CType(oOutlook.CreateItem(Outlook.OlItemType.olMailItem), Outlook.MailItem) oMailitem.To = "" oMailitem.Subject = "Order Request" Dim MailBody As String = "Hi," _ & ControlChars.NewLine _ & "Please could you place orders as per the requirement below" _ & ControlChars.NewLine _ & "I WANT THIS LINE BOLD....." _ & ControlChars.NewLine _ & "Thanks!!"

    L 1 Reply Last reply
    0
    • R RichardBerry

      Hi I'm using the following code to create an outlook mail message, but need to bold and undeline certain lines in the message body. How can I do this? Dim oOutlook As New Outlook.Application Dim oMailitem As Outlook.MailItem oMailitem = CType(oOutlook.CreateItem(Outlook.OlItemType.olMailItem), Outlook.MailItem) oMailitem.To = "" oMailitem.Subject = "Order Request" Dim MailBody As String = "Hi," _ & ControlChars.NewLine _ & "Please could you place orders as per the requirement below" _ & ControlChars.NewLine _ & "I WANT THIS LINE BOLD....." _ & ControlChars.NewLine _ & "Thanks!!"

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      Hmmm I havent tried this yet but here are some suggestions: If the users are recieving the mail as html you could use html tags in you msg.Body Or since outlook uses word as its email editor - open up word (in code and see what functionality this offers you) Hope these pointers help If i get time to look into this i shall try them and let you know my results Dan

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups