Results 1 to 9 of 9

Thread: Convert RPT to PDF and send it in email

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2005
    Posts
    7

    Convert RPT to PDF and send it in email

    Hi,
    I want to convert my report to a pdf format and send it via email...I'm using the outlook application and i searched for codes to how to send email and got this code:

    VB Code:
    1. Dim mOutLookApp As Outlook.Application
    2. Dim mNameSpace As Outlook.Namespace
    3. Dim mItem As Outlook.MailItem
    4.  
    5. Set mOutLookApp = New Outlook.Application
    6. Set mNameSpace = mOutLookApp.GetNamespace("MAPI")
    7. mNameSpace.Logon , , False, True
    8.  
    9.     Set mItem = mOutLookApp.CreateItem(olMailItem)
    10.     mItem.To = strEmailAddress
    11.     mItem.Subject = "This is for you"
    12.     mItem.HTMLBody = strMessage
    13.    
    14.     mItem.Sensitivity = olConfidential
    15.     mItem.Importance = olImportanceHigh
    16.    
    17.     mItem.Send

    I got compile error in line one (mOutLookApp )that the user-defined type is not defined!!

    How can i solve the problem?!!!

    Please help me.
    Last edited by RobDog888; Sep 12th, 2005 at 11:19 PM. Reason: Added vbcode tags

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width