以下是引用chenwintek在2005-6-20 11:29:00的发言:
后来,察看IE.document,发现更简单的办法:其innerText就直接有TXT文本,截取之,即可。
Const sURI As String = "http://book.sina.com.cn/longbook/tech/1100774586_zengguofanshengqian/88.shtml"
Dim ie As Object
Dim strDoc As Object
Set ie = CreateObject("internetexplorer.application")
ie.Navigate sURI
Set strDoc = ie.Document
Debug.Print strDoc.body.innerText
Debug.Print strDoc.body.innerHTML
用此方法提示:方法‘document’作用于对象‘IWebBrowser2’时失败
欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/) | Powered by Discuz! X3.3 |