Upload a file with POST (multipart / form-data) using VBA

Possible duplicate:
Creating a POST body in VBA

Does anyone know if it is possible to upload a file through a POST body (multipart / form-data) using VBA? I am currently using the Microsoft.XMLHTTP object, but I am not attached to it unless it supports multi-page POST.

Here is what I am doing so far:

Set oHttp = CreateObject("Microsoft.XMLHTTP") oHttp.Open "POST", theUrl, False oHttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded" oHttp.Send "body=thebody" 
+4
source share

Source: https://habr.com/ru/post/1308939/


All Articles