Hi,

I am new to AD and networking,

I'd like to get all online clients'IP addresses (that be e.g \\192.168.1.xxx\Client1, \\192.168.1.xxx\Client2, \\192.168.1.xxx\Client3 , etc)

My code in Linux is
Code:
int main() 
{ 
  const char* const host = "computername" ; 
  const hostent* host_info = 0 ; 
  host_info = gethostbyname(host) ; 
 
  if(host_info) 
  { 
    std::cout << "host: " << host_info->h_name << '\n' ; 
 
    for( int i=0 ; host_info->h_addr_list[i] ; ++i ) 
    { 
      const in_addr* address = (in_addr*)host_info->h_addr_list[i] ; 
      std::cout << " address: " << inet_ntoa( *address ) << '\n' ; 
    } 
  } 
  else herror( "error" ) ; 
}
I'd like to do this in a pure MFC application, what api functions should I look up ?

Thank you.