in "ThisWorkbook" add the following code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Sheets("Data").Range("AE1").Value = 1 Then ' specify the cell you want to activate your macro here
Run "Test"
End If
End Sub
then in a module, insert your macro. for example
Sub Test()
Dim IE As Object
Sheets("Arg").select
Range("G3:BV1000").clearcontents
Range("G3").Select
Set IE = CreateObject("InternetExplorer.Application")
With IE
.Visible = True
.Navigate "http://www.leagueday.com/latest.asp?league=argentina" ' should work for any URL
Do Until .ReadyState = 4: DoEvents: Loop
End With
IE.ExecWB 17, 0 '// SelectAll
IE.ExecWB 12, 2 '// Copy selection
ActiveSheet.Paste
Range("G3").Select
IE.Quit
IE.Quit ' just to make sure
Sheets("Data").Select
Range("A1").Select
End Sub
End If
End Sub
Bookmarks