MIQueryInfo() function - MapBasic - 2023

MapInfo MapBasic Reference

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapBasic
Version
2023
ft:locale
en-US
Product name
MapBasic
ft:title
MapInfo MapBasic Reference
First publish date
1985
ft:lastEdition
2023-09-12
ft:lastPublication
2023-09-12T16:32:32.686000

Purpose

Returns response or request headers from an HTTP request.

Syntax

MIQueryInfo( ByVal hFile As CHttpFile, ByVal dwInfoLevel As Integer, 
	pBuffer As String, pBufferLength As Integer ) As SmallInt

hFile is a CHttpFile handle.

dwInfoLevel is a combination of the attribute to query, and a modifier flag that specifies the type of information requested: For a list of the modifier flags, refer to the Microsoft MSDN library.

pBuffer is a reference to a string that receives the information. For the attribute HTTP_QUERY_CUSTOM, pBuffer is also an input indicating which header name to query.

pBufferLength is a reference to an integer that contains the length of pBuffer in number of characters or bytes on entry. When the function succeeds (a string is written to pBuffer), it contains the length of the string in characters minus 1 for the terminating NULL character.

Return Value

Nonzero if successful; otherwise 0. To determine the cause of the failure, call the MIGetErrorMessage() function.

Description

Use this function to get response or request headers from an HTTP request. For a description of attribute values, refer to the Microsoft MSDN library for information on Query Info flags (https://msdn.microsoft.com/en-us/library/windows/desktop/aa385351(v=vs.85).aspx).