This code works and uploads a zip file to a server.
It runs on Linux
curl -F zipFile=@filename.zip -u userxx : passwxx "server url”
How can I send the file using B4A and HTTP PostMultipart?
this code fails (Bad Request etc)
any help appreciated
George
It runs on Linux
curl -F zipFile=@filename.zip -u userxx : passwxx "server url”
How can I send the file using B4A and HTTP PostMultipart?
this code fails (Bad Request etc)
B4X:
Dim fd As MultipartFileData
Dim fname As String= P_ID & ".zip"
Dim dirname As String= File.Combine( Starter.ArchiveFolder,P_ID)
fd.Initialize
fd.Dir = dirname
fd.FileName =fname
fd.KeyName = "zipFile"
Dim j As HttpJob
j.Initialize("j", Me)
j.Username="userxx"
j.Password="passwxx"
j.PostMultipart( "server url",Null ,Array(fd))
George