Salve a tutti tramite questa "chiamata" di sub
io richiamo un sub che mi fa l'uplod di alcuni file sul server remotocodice:File.SaveToDisk strPath
questa è la sub:
dove sPath è il percorso della cartella dove ho i permessi di scrittura sul server.codice:Public Sub SaveToDisk(sPath) Dim oFS, oFile Dim nIndex If sPath = "" Or FileName = "" Then Exit Sub If Mid(sPath, Len(sPath)) <> "\" Then sPath = sPath & "\" Set oFS = Server.CreateObject("Scripting.FileSystemObject") If Not oFS.FolderExists(sPath) Then Exit Sub Set oFile = oFS.CreateTextFile(sPath & FileName, True) For nIndex = 1 to LenB(FileData) oFile.Write Chr(AscB(MidB(FileData,nIndex,1))) Next oFile.Close End Sub
Tutto mi funziona correttamente ma se io volessi chiamare questo file prova.pdf come posso modificare la sub?

Rispondi quotando