c4mpi Posted March 22, 2010 Posted March 22, 2010 #include <IE.au3> $oIE = _IECreate() _IENavigate($oIE, "http://pda.hko.gov.hk/wxreporte.htm") $oTable2 = _IETableGetCollection($oIE, 1) $aWeather = _IETableWriteToArray($oTable2) For $i = 0 to Ubound($aWeather, 2) - 1 ConsoleWrite("City: " & $aWeather[0][$i] & " --> Temp: " & $aWeather[1][$i] & @CR) Next Exit Why doesnt this code work?
setirich Posted March 22, 2010 Posted March 22, 2010 (edited) You've neglected to #include <array.au3> I tested your code with the additional include....and it works !!!! Congratulations! Edited March 22, 2010 by setirich Good intentions will always be pleaded for every assumption of authority. It is hardly too strong to say that the Constitution was made to guard the people against the dangers of good intentions. There are men in all ages who mean to govern well, but they mean to govern. They promise to be good masters, but they mean to be masters.-Daniel Webster
PsaltyDS Posted March 22, 2010 Posted March 22, 2010 You've neglected to #include <array.au3> I tested your code with the additional include....and it works !!!! Congratulations! No. Array.au3 is not required to use _IETableWriteToArray(). And if it were, Dale would have included it internally in the IE.au3 UDF. This works fine without Array.au3 included: #include <IE.au3> $oIE = _IE_Example("Table") $oTable2 = _IETableGetCollection($oIE, 1) $aWeather = _IETableWriteToArray($oTable2) For $i = 0 to Ubound($aWeather, 2) - 1 ConsoleWrite("City: " & $aWeather[0][$i] & " --> Temp: " & $aWeather[1][$i] & @CR) Next Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now