·  Start ·  Programme ·  Codes ·  Tipps ·  ActiveX ·  Tutorials · 



Dateidownload ohne Dialog. Lädt eine beliebige Datei und speichert diese am Zielort.

Private Declare Function URLDownloadToFile Lib "urlmon" _
    Alias "URLDownloadToFileA" (ByVal pCaller As Long, _
    ByVal szURL As String, _
    ByVal szFileName As String, _
    ByVal dwReserved As Long, _
    ByVal lpfnCB As Long) As Long
 
Private Const FileToDownload = "http://www.irgendwer.com/test.html"
Private Const DestFile = "C:\test.txt"

Private Sub Command1_Click()
Dim urlSuccess As Long
' Starte Download
urlSuccess = URLDownloadToFile(0, FileToDownload, DestFile, 0, 0)
    Select Case urlSuccess
        Case 0
            ' erfolgreicher Download
            MsgBox "Download erfolgreich beendet"
        Case Else
            MsgBox "Error..."
    End Select
End Sub
Aktualisiert: 12.02.2008, 14:11 Uhr Copyright © 2001 - 2010 by ST-software Navigation zurück  |  Navigation vorwärts  |  Zum Seitenanfang     
Ihre IP: 38.107.191.82 ·  Seite erstellt in: 0.797 Sekunden ·  Dateigröße:  2743 Bytes