Creating a POST body in VBA

Does anyone know how to build a POST DATA body in VBA? I am trying to load fairly long lines through a post call using the "Microsoft.XMLHTTP" object. I am not tied to using this object to request an HTTP request.

+5
source share
1 answer

What about

Dim XMLHttp As Object: Set XMLHttp = CreateObject("Microsoft.XMLHTTP") XMLHttp.Open "POST", "http://www.lfkfklkf.com", False XMLHttp.setRequestHeader "Content-Type", "application/x-www-form-urlencoded" XMLHttp.send "q=ploppy&x=cake" Debug.print XMLHttp.responseText Set XMLHttp = Nothing 
+5
source

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


All Articles