PDA

View Full Version : Solved: Restrict download area



omnibuster
09-16-2009, 08:31 AM
Hi.
In my workbook this code works fine and download Lists good.
(But very slow if List contained 10 000 or more names, no-s.)
So i dont need download 3-rd columns what contained numbers like 0,00%.
Data like this:
John Smith 4000 0,098%
http://web.zone.ee/omnibuster/ASR1.HTML

For Each tr In colTR
Set colTD = tr.GetElementsByTagName("TD")
iCol = 1
For Each td In colTD
ActiveCell(iRow, iCol).Value = td.innertext
iCol = iCol + 1
Next td
iRow = iRow + 1
Next tr


How to say: dont download 0,098%.
In the cell excel says: Number stored as text.


For Each tr In colTR
Set colTD = tr.GetElementsByTagName("TD")
iCol = 1
For Each td In colTD
If td.innertext <> "*%" Then
ActiveCell(iRow, iCol).Value = td.innertext
iCol = iCol + 1
End If
Next td
iRow = iRow + 1
Next tr

omnibuster
09-17-2009, 09:33 AM
Thaks for looking.
I find solution, but still slow??

For Each tr In colTR
Set colTD = tr.GetElementsByTagName("TD")
iCol = 1
For Each td In colTD
If Right(td.innertext, 1) <> "%" Then
ActiveCell(iRow, iCol).Value = td.innertext
iCol = iCol + 1
End If
Next td
iRow = iRow + 1
Next tr