将网站数据复制到 XL 2003
我正在尝试将网站数据复制到 XL 2003 有人告诉我可以使用“发送密钥”,但它不起作用。 请有人帮助我。
Sub CopyInternetDoc()
Dim IntApp As Object
Set IntApp = CreateObject("InternetExplorer.Application")
With IntApp
' Change file name to suit
.Visible = True
.Navigate "http://test/"
CODE TO COPY data from "http://test/" to Excel
End With
ActiveSheet.Cells.Select
Selection.ClearContents
ActiveSheet.range("A1").Select
ActiveSheet.Paste
IntApp.Quit
Set IntApp = Nothing
End Sub
I am trying to copy website data to XL 2003
I was told about using "send keys" but it doesn't work.
Please could someone help me.
Sub CopyInternetDoc()
Dim IntApp As Object
Set IntApp = CreateObject("InternetExplorer.Application")
With IntApp
' Change file name to suit
.Visible = True
.Navigate "http://test/"
CODE TO COPY data from "http://test/" to Excel
End With
ActiveSheet.Cells.Select
Selection.ClearContents
ActiveSheet.range("A1").Select
ActiveSheet.Paste
IntApp.Quit
Set IntApp = Nothing
End Sub
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果它适合您的数据源,您可以尝试使用“网络查询”。 基本上,您只需设置一个带有 URL 参数的 QueryTable; 请参阅 http://msdn.microsoft.com/en-us/library/aa203721 .aspx 了解更多详细信息。
If it's appropriate for your data source, you could try using "web queries" instead. Basically, you just set up a QueryTable with an URL parameter; see http://msdn.microsoft.com/en-us/library/aa203721.aspx for more details.