Skip to content

Latest commit

 

History

History
114 lines (83 loc) · 5.08 KB

nf-wininet-httpsendrequestexw.md

File metadata and controls

114 lines (83 loc) · 5.08 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:wininet.HttpSendRequestExW
HttpSendRequestExW function (wininet.h)
Sends the specified request to the HTTP server. (HttpSendRequestExW)
HttpSendRequestEx
HttpSendRequestEx function [WinINet]
HttpSendRequestExW
_win32_httpsendrequestex
wininet.httpsendrequestex
wininet/HttpSendRequestEx
wininet/HttpSendRequestExW
wininet\httpsendrequestex.htm
wininet
3362fcd2-e8df-4886-9525-bf60589b2c1f
12/05/2018
HttpSendRequestEx, HttpSendRequestEx function [WinINet], HttpSendRequestExA, HttpSendRequestExW, _win32_httpsendrequestex, wininet.httpsendrequestex, wininet/HttpSendRequestEx, wininet/HttpSendRequestExA, wininet/HttpSendRequestExW
wininet.h
Windows
Windows 2000 Professional [desktop apps only]
Windows 2000 Server [desktop apps only]
HttpSendRequestExW (Unicode) and HttpSendRequestExA (ANSI)
Wininet.lib
Wininet.dll
Windows
19H1
HttpSendRequestExW
wininet/HttpSendRequestExW
c++
APIRef
kbSyntax
DllExport
Wininet.dll
HttpSendRequestEx
HttpSendRequestExA
HttpSendRequestExW

HttpSendRequestExW function

-description

Sends the specified request to the HTTP server.

Note  Callers that need to send extra data beyond what is normally passed to HttpSendRequestEx can do so by calling HttpSendRequest instead.
 

-parameters

-param hRequest [in]

A handle returned by a call to the HttpOpenRequest function.

-param lpBuffersIn [in]

Optional. A pointer to an INTERNET_BUFFERS structure.

-param lpBuffersOut [out]

Reserved. Must be NULL.

-param dwFlags [in]

Reserved. Must be zero.

-param dwContext [in]

Application-defined context value, if a status callback function has been registered.

-returns

If the function succeeds, the function returns TRUE.

If the function fails, it returns FALSE. To get extended error information, call GetLastError.

-remarks

HttpSendRequestEx performs both the send and the receive for the response. This does not allow the application to send any extra data beyond the single buffer that was passed to HttpSendRequestEx. Callers that need to send extra data beyond what is normally passed to HttpSendRequestEx can do so by calling HttpSendRequest instead. After the call to HttpSendRequestEx, send the remaining data by calling InternetWriteFile. Finally, follow up with a call to HttpEndRequest.

Note  The HttpSendRequestExA function represents data to send as ISO-8859-1 characters not ANSI characters. The HttpSendRequestExW function represents data to send as ISO-8859-1 characters converted to UTF-16LE characters. As a result, it is never safe to use the HttpSendRequestExW function when the headers to be added can contain non-ASCII characters. Instead, an application can use the MultiByteToWideChar and WideCharToMultiByte functions with a Codepage parameter set to 28591 to map between ANSI characters and UTF-16LE characters.
 
Note  WinINet does not support server implementations. In addition, it should not be used from a service. For server implementations or services use Microsoft Windows HTTP Services (WinHTTP).
 

Note

The wininet.h header defines HttpSendRequestEx as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.

-see-also

HTTP Sessions

WinINet Functions