• DİKKAT

    DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
    Altın Üyelik Hakkında Bilgi

siteden veri çekme

Dosya ekte...

Kod:
'http://www.lototurkiye.com/v5/p_go2.asp?pt=s_lotogrid
Sub Get_Table_From_HTML()
'Dim doc As New HTMLDocument ' Microsoft HTML Object Library
Columns("a:bb").ClearContents

Set HTTP = CreateObject("MSXML2.XMLHTTP")
Set doc = CreateObject("HTMLFile")

HTTP.Open "get", _
"http://www.lototurkiye.com/v5/p_go2.asp?pt=s_lotogrid", False
HTTP.send

doc.write (StrConv(HTTP.responsebody, vbUnicode))

Set tbl = doc.getElementsByTagName("table").Item(22)

For i = 0 To tbl.Rows.Length - 1
    For j = 0 To tbl.Rows(i).Cells.Length - 1
        Cells(i + 1, j + 1) = tbl.Rows(i).Cells(j).innerText
    Next
Next

Set tbl = Nothing
Set doc = Nothing
Set HTTP = Nothing

MsgBox "İşlem tamamlandı", vbInformation
End Sub
 

Ekli dosyalar

Geri
Üst