Results 1 to 2 of 2

Thread: how to send a FSO as e-mail attachment?

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Apr 2005
    Posts
    129

    how to send a FSO as e-mail attachment?

    Hi all

    I have created a File system object (basicly a text file)

    When the user pressed the Email button on my applicatio i wish for thier default email application to fire up and the FSO i have created to be attached to a email with a Email address and header allready set in place.
    how can i do this??

    Many thanks

  2. #2
    Banned programmer_boy's Avatar
    Join Date
    Sep 2005
    Location
    Netherlands
    Posts
    26

    Re: how to send a FSO as e-mail attachment?

    I don't know how to attach a file to an email using this way, but to fire up the email application goes like this:

    VB Code:
    1. Option Explicit
    2.  
    3. Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _
    4. (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, _
    5. ByVal lpParameters As String, ByVal lpDirectory As String, _
    6. ByVal nShowCmd As Long) As Long
    7.  
    8. Private Const SW_SHOWNORMAL = 1
    9.  
    10. sEmailCmd As String
    11. sEmailCmd = "mailto:[email protected]?subject=MyProgram"
    12.  
    13. ShellExecute Me.hwnd, vbNullString, sEmailCmd, vbNullString, "C:\", SW_SHOWNORMAL

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