使用 CInternetSession 类和 CHttpFile 类;
在stdafx.h中加入 #include <afxinet.h> ;
基本的代码如下,
            
            
              cpp
              
              
            
          
          void CMFCApplication3Dlg::OnBnClickedButton1()
{
	// TODO: 在此添加控件通知处理程序代码
	try
	{
		CInternetSession session;
		CHttpFile* file = (CHttpFile*)session.OpenURL(_T("http://localhost/"));
		//读取数据
		CString content;
		CString temp;
		while (file->ReadString(temp))
		{
			content += temp;
		}
		//网络流一般是UTF8 需要转换
		CString convert = CA2T((LPCSTR)content.GetBuffer());
		m_edit.SetWindowText(convert);
		//释放资源
		file->Close();
		session.Close();
		delete file;
	}
	catch (CInternetException* e)//异常处理
	{
		TCHAR sz[512] = { 0 };
		e->GetErrorMessage(sz, 512);
		AfxOutputDebugString(sz);
		e->Delete();
	}
}
进一步可以查找一些字符串等;
有时间继续;