Home |
Search |
Today's Posts |
#7
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Ron
Regards Alvin "Ron de Bruin" wrote: Hi Alvin Download the workbook examples from this book http://www.wrox.com/WileyCDA/WroxTit...load_code.html There is a file named ExchangeRates.xls -- Regards Ron de Bruin http://www.rondebruin.nl "alvin Kuiper" wrote in message ... Hi Ron I don'rt no why but if i try this i don't get data in my sheet well yes i get data but not the currency I have try with Sub HentInfo() Dim oIE As SHDocVw.InternetExplorer Dim sPage As String Dim intStart, intSlut As Long Dim Info As String Set oIE = New SHDocVw.InternetExplorer oIE.Navigate "http://www.valutakurser.dk" Do Until oIE.ReadyState = READYSTATE_COMPLETE DoEvents Loop sPage = oIE.Document.body.InnerHtml intStart = InStr(1, sPage, "<!-- Nationalbankens Middelkurser - Start --") intSlut = InStr(intStart, sPage, "<!-- Nationalbankens Middelkurser - Slut --") Info = Mid(sPage, intStart, intSlut - intStart) MsgBox Info End Sub but dont know what to do Alvin "Ron de Bruin" wrote: One way is to open the page Sub test() Workbooks.Open "http://www.valutakurser.dk/" End Sub And delete the columns you not want -- Regards Ron de Bruin http://www.rondebruin.nl "alvin Kuiper" wrote in message ... hi i have found this examble: Sub HentInfo() Dim oIE As SHDocVw.InternetExplorer Dim sPage As String Dim intStart, intSlut As Long Dim Info As String Set oIE = New SHDocVw.InternetExplorer oIE.Navigate "http://www.dr.dk" Do Until oIE.ReadyState = READYSTATE_COMPLETE DoEvents Loop sPage = oIE.Document.body.InnerHtml intStart = InStr(1, sPage, "Vejret") intSlut = InStr(intStart, sPage, "læs mere") Info = Mid(sPage, intStart, intSlut - intStart + 8) MsgBox Info End Sub But get an error in Info = Mid(sPage, intStart, intSlut - intStart + 8) To bee honest i don't know what the script do all the way regards alvin |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
geting a if/and number off of two list cells | Excel Worksheet Functions | |||
geting the smaller number in a line?? | Excel Discussion (Misc queries) | |||
Question that should be easy but is geting on my nerves :) | Excel Discussion (Misc queries) | |||
geting hiperlink wiyh vlookup | Excel Worksheet Functions | |||
Erroe on Geting External Data | Excel Programming |