Odeslßnφ poÜty s p°ipojen²m souborem

Postup:
Na formulß° p°idejte tlaΦφtko. Do deklaraΦnφ Φßsti formulß°e zapiÜte
:

Private Declare Function ShellExecute Lib "shell32.dll" Alias _
   "ShellExecuteA" (ByVal hWnd As Long, _
   ByVal lpOperation As String, ByVal lpFile As String, _
   ByVal lpParameters As String, ByVal lpDirectory As String, _
   ByVal nShowCmd As Long) As Long

Na udßlost click tlaΦφtka:

Private Sub Command1_Click()

   Call ShellExecute(0&, vbNullString,_
    "mailto:bozena@army.cz?subject=Nazdar&body=pokus&_
    attach=" + Chr(34) + "c:\imp.txt" + Chr(34), _
    vbNullString, vbNullString, vbNormalFocus)

End Sub

Zßkladnφ v∞cφ je, ₧e pro parametr attach se musφ soubor zadat v uvozovkßch, tudφ₧ je nutnΘ tyto uvozovky vΦlenit do °et∞zce - d∞je se tak pomocφ chr(34).

Zp∞t

Autor: The Bozena