[DllImport("wininet.dll", SetLastError=true)]
static extern bool InternetQueryOption(IntPtr hInternet, uint dwOption, char[] lpBuffer, ref int lpdwBufferLength);
<DllImport("wininet.dll", SetLastError:=True)> Shared Function InternetQueryOption(ByVal hInternet As IntPtr, ByVal dwOption As UInteger, ByVal lpBuffer() As Char, ByRef lpdwBufferLength As Integer) As Boolean
End Function
None.
In order to set new proxy settings use InternetSetOption.
Please add some!
Retrieve WinInet version in C#:
const int INTERNET_OPTION_VERSION = 40;
[StructLayout(LayoutKind.Sequential)]
public struct INTERNET_VERSION_INFO
{
public int dwMajorVersion;
public int dwMinorVersion;
};
// Note that I named the imported fcn "InternetQueryVersion" due to custom arg signature
[DllImport("wininet.dll", EntryPoint = "InternetQueryOption")]
private extern static bool InternetQueryVersion(int Handle, int OptionFlag, ref INTERNET_VERSION_INFO Version, ref int size);
INTERNET_VERSION_INFO Version = new INTERNET_VERSION_INFO();
int size = Marshal.SizeOf(Version);
bool r = InternetQueryVersion(0, INTERNET_OPTION_VERSION, ref Version, ref size);
Do you know one? Please contribute it!