copy website to worksheet

C

Chris

Hello all,

I want to copy a frame from a website to my excel worksheet. with some
sendkeys actions i selected the right frame, but i can't copy it.
Is there a simple way to get this done?
Here is my code i used now.

Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True


'Go to this Web Page!
IE.Navigate "myURL"


'Check for good connection to web page loop!
Do
If IE.ReadyState = 4 Then
IE.Visible = False
Exit Do
Else
DoEvents
End If
Loop


'Wait for window to open!
Application.Wait (Now + TimeValue("0:00:01"))
'MsgBox "Done"
IE.Visible = True


'Send logg-on information!
'May need additional SendKeys as needed?
'Determine by the actual key-stroks needed!

Password = Sheets("blad1").Cells(2, 1).Value
Inlogname = Sheets("blad1").Cells(1, 1).Value
SendKeys (Inlogname), True
SendKeys "{TAB}", True
SendKeys (Password), True
SendKeys "{ENTER}", True
Application.Wait (Now + TimeValue("0:00:03"))
SendKeys "^{TAB}"
SendKeys "^{TAB}"
SendKeys "^{TAB}"
SendKeys "^{TAB}"
SendKeys "^{TAB}"
SendKeys "^{TAB}"

End Sub

Under the last sendkeys i tried selection.copy, but then he copy's the
selection of the worksheet and not the one from the page.
I don't know what there is wrong, but i hope someone of you can give me
hint.

Thanks Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top