Click here to Skip to main content
15,920,632 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralPlease Help!!! Opening Multiple DataAdapters at same time Gives error Pin
Tasnim21-Jan-04 19:32
Tasnim21-Jan-04 19:32 
GeneralRe: Please Help!!! Opening Multiple DataAdapters at same time Gives error Pin
Serge Lobko-Lobanovsky28-Jan-04 4:59
Serge Lobko-Lobanovsky28-Jan-04 4:59 
Generalaudio player Pin
nightmare0121-Jan-04 17:00
nightmare0121-Jan-04 17:00 
GeneralRe: audio player Pin
Dave Kreskowiak22-Jan-04 1:19
mveDave Kreskowiak22-Jan-04 1:19 
QuestionOffline database........? Pin
opusxxvii21-Jan-04 16:24
opusxxvii21-Jan-04 16:24 
AnswerRe: Offline database........? Pin
Dave Kreskowiak22-Jan-04 1:17
mveDave Kreskowiak22-Jan-04 1:17 
GeneralRe: Offline database........? Pin
opusxxvii22-Jan-04 8:23
opusxxvii22-Jan-04 8:23 
GeneralRe: Offline database........? Pin
Dave Kreskowiak22-Jan-04 11:31
mveDave Kreskowiak22-Jan-04 11:31 
"Scrape"ing is grabbing a page and searching through it looking for certain tags or other strings that either delineate the information you want or point to the information you want. In other words, you'll treat the page source (HTML) as a string and search that string for substrings that represents the data you want, or the tags around it. For example:

<td class="yfnc_tablehead1" width="48%">Last Trade:</td><td class="yfnc_tabledata1"><big>28.01</big></td></tr><tr><td class="yfnc_tablehead1" width="48%">Trade Time:</td><td 
class="yfnc_tabledata1">4:00PM ET</td></tr><tr><td class="yfnc_tablehead1" width="48%">Change:</td><td 
class="yfnc_tabledata1"><img width="10" height="14" border="0" 
src="http://us.i1.yimg.com/us.yimg.com/i/us/fi/03rd/down_r.gif" alt="Down""color: rgba(204, 0, 0, 1)">0.29 (1.02%)</td></tr><tr>


This is just a few lines of the 38,000 characters returned by Yahoo Finance to display the data for a quote on Microsoft. There are 3 bits of useful information in this snippet. The "Last Trade", "Trade Time", and "Change". Find them... I'l wait.

Now, you can use the strings "Last Trade", "Trade Time", and "Change" to find where the information is, but it doesn't give you the information you want. Once you find the string "Last Trade", you have to skip a bunch of stuff before you can actually get to the data you need, 28.01. The problem is how do you RELIABLY skip to that piece of information? Hint: The web page isn't as stable as it appears!

You might want to look at this MSDN article[^] first before deciding whether or not this method is acceptable.



RageInTheMachine9532
GeneralRe: Offline database........? Pin
-Dr_X-24-Jan-04 13:41
-Dr_X-24-Jan-04 13:41 
GeneralCorrupt Text Files Pin
Barry Etter21-Jan-04 13:11
Barry Etter21-Jan-04 13:11 
GeneralRe: Corrupt Text Files Pin
Mike Ellison21-Jan-04 14:39
Mike Ellison21-Jan-04 14:39 
GeneralRe: Corrupt Text Files Pin
Dave Kreskowiak22-Jan-04 1:02
mveDave Kreskowiak22-Jan-04 1:02 
Generallistview + selecteditem Pin
Anonymous21-Jan-04 11:17
Anonymous21-Jan-04 11:17 
GeneralRe: listview + selecteditem Pin
Dave Kreskowiak22-Jan-04 0:57
mveDave Kreskowiak22-Jan-04 0:57 
GeneralLooking for IT Professionals on H1B Visa Transfer/Faster GreenCard Processing Pin
Keith_00221-Jan-04 10:42
Keith_00221-Jan-04 10:42 
GeneralRe: Looking for IT Professionals on H1B Visa Transfer/Faster GreenCard Processing Pin
keshavcode21-Jan-04 14:59
keshavcode21-Jan-04 14:59 
GeneralFirewall HELP Pin
zoodayz21-Jan-04 9:33
zoodayz21-Jan-04 9:33 
GeneralRe: Firewall HELP Pin
Dave Kreskowiak22-Jan-04 0:50
mveDave Kreskowiak22-Jan-04 0:50 
GeneralExit Code From VB application Pin
ANORTON21-Jan-04 5:27
ANORTON21-Jan-04 5:27 
GeneralRe: Exit Code From VB application Pin
Dave Kreskowiak21-Jan-04 6:20
mveDave Kreskowiak21-Jan-04 6:20 
GeneralRe: Exit Code From VB application Pin
ANORTON21-Jan-04 7:51
ANORTON21-Jan-04 7:51 
Generalclient server Pin
noureddine01010121-Jan-04 5:08
noureddine01010121-Jan-04 5:08 
GeneralRe: client server Pin
Mike Ellison21-Jan-04 15:02
Mike Ellison21-Jan-04 15:02 
QuestionHow to select an Item in a Listview Pin
code_gopher21-Jan-04 4:52
code_gopher21-Jan-04 4:52 
AnswerRe: How to select an Item in a Listview Pin
Mike Ellison21-Jan-04 14:54
Mike Ellison21-Jan-04 14:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.