O n c l i c k javascript

Smat90

New Member
Joined
Apr 21, 2016
Messages
2
Ciao a tutti

Ho un problema vorrei scrivere uno script vba per copiare alcuni dati da una tabella in questo sito: http://www.ecb.europa.eu/stats/money/yc/html/index.en

i dati non sono visibili subito ma bisogna selezionare il tag "Yields" in alto a destra rispetto al grafico.
a quel punto appare la tabella da cui vorrei copiare i dati.

il problema principale è che non riesco a azionare il comando O n c l i c k per poi copiare i dati.

questo (penso) dovrebbe essere il comando eseguito
o n c l i c k="javascript:charts[0].switchDimension(1,1);"

e questo il codice scritto da me:


rivate Sub CommandButton1_Click()


Dim termine As String
Dim tasso As String


termine = ""
tasso = ""


the_start:

Set objIE = CreateObject("internetExplorer.Application")
objIE.Top = 0
objIE.Left = 0
objIE.Width = 800
objIE.Height = 600
objIE.Visible = True 'vediamo la finestra
<span")

On Error Resume Next

objIE.navigate ("http://www.ecb.europa.eu/stats/money/yc/html/index.en.html")

'per aspettare che la pagina si carica
Do
DoEvents

If Err.Number <> 0 Then
objIE.Quit
Set objIE = Nothing
GoTo the_start

End If


Loop Until objIE.ReadyState = 4


IE.document.all.item
Call IE.document.parentWindow.execScript("javascript:charts[0].switchDimension(1,1);", "JavaScript")


Grazie a tutti</span")
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.

Forum statistics

Threads
1,223,631
Messages
6,173,465
Members
452,516
Latest member
archcalx

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top