Версия для печати темы
Нажмите сюда для просмотра этой темы в оригинальном формате
Форум программистов > Delphi: Общие вопросы > GetTcpTable


Автор: Spawn 18.11.2002, 02:39
Почитал тут литературу про WinSock и NetBIOS и нашел там описание функции GetTcpTable, которая должна возвращать массив структур, описывающих количество активных TCP соединений, их локальный порт и адресс, удаленный порт и адрес и состояние сокета, но в MSDN описание этой функции нету. Подскажите пожалуйста, где ее можно взять(проэкспортировать).

Автор: Baa 18.11.2002, 11:56
Вот тебе из мсдн кусок
Header: Declared in Iphlpapi.h.
 Library: Use Iphlpapi.lib.
GetTcpTable
The GetTcpTable function retrieves the TCP connection table.

DWORD GetTcpTable(
 PMIB_TCPTABLE pTcpTable,  // buffer for the connection table
 PDWORD pdwSize,           // size of the buffer
 BOOL bOrder               // sort the table?
);
Parameters
pTcpTable
[out] Pointer to a buffer that receives the TCP connection table as a MIB_TCPTABLE structure.
pdwSize
[in, out] On input, specifies the size of the buffer pointed to by the pTcpTable parameter.
On output, if the buffer is not large enough to hold the returned connection table, the function sets this parameter equal to the required buffer size.

bOrder
[in] Specifies whether the connection table should be sorted. If this parameter is TRUE, the table is sorted in the order of:
Local IP address
Local port
Remote IP address
Remote port
Return Values
If the function succeeds, the return value is NO_ERROR.

If the function fails, use FormatMessage to obtain the message string for the returned error.

Автор: Spawn 18.11.2002, 14:29
Хм, странно, я вводил в поле поиска ето значение и результатов не было!

Автор: AntonSaburov 19.11.2002, 00:58
Смотря от какого числа MSDN :)

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)