in need to get data from a site that search a doctor name in spec. city
i have some of the code and thats working but on the site you can filter is specialism thats now the part that i don't can add in my code
so i can pull data filtering by city and name so that specialism a want to add in my filter before i pull the data from the site
i insert a pic with the option marked that i want to add in my code
thx
i have some of the code and thats working but on the site you can filter is specialism thats now the part that i don't can add in my code
so i can pull data filtering by city and name so that specialism a want to add in my filter before i pull the data from the site
i insert a pic with the option marked that i want to add in my code
thx
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Row = Range("naam").Row And Target.Column = Range("naam").Column Then
If Target.Row = Range("gemeente").Value > "" Then 'Row And Target.Column = Range("gemeente").Column Then
Dim ie As New InternetExplorer
ie.Visible = True
ie.navigate "https://www.ordomedic.be/nl/zoek-een-arts/?search_name=" & Range("naam") & "&+search_place=" & Range("gemeente") & "&+search_specialism"
Do
DoEvents
Loop Until ie.readyState = READYSTATE_COMPLETE
Dim doc As HTMLDocument
Set doc = ie.document
Dim sdd2, sdd3, sdd4, sdd5, sdd0 As String
sdd2 = Trim(doc.getElementsByTagName("dd")(2).innerText)
sdd3 = Trim(doc.getElementsByTagName("dd")(3).innerText)
sdd4 = Trim(doc.getElementsByTagName("dd")(4).innerText)
sdd5 = Trim(doc.getElementsByTagName("dd")(5).innerText)
sdd0 = Trim(doc.getElementsByTagName("dd")(0).innerText)
Dim LString As String
Dim LArray() As String
LString = sdd0
LArray = Split(LString, " ")
Range("k10") = LArray(1) & " " & LArray(0)
'Range("k10") = LArray(1)
'Range("k10") = sdd0
Range("k11") = sdd2
Range("k12") = sdd3
Range("k13") = sdd5
End If
End If
End Sub