Lanc1988 Posted February 2, 2005 Posted February 2, 2005 I made a simple project that gets the source code of a website then puts it in a rich text box. But i also want it to then look through the code for some numbers (these numbers change because they are the high scores for a game) Here is a section of the source code: <tr><td><img src="http://www.runescape.com/img/hiscores/attack.gif" valign="bottom" width=16 height=16 /></td><td> </td> <td><a href="hiscoreuser.cgi?username=lanc1988&category=1" class=c>Attack</a></td> <td align="right">48,303</td><td align="right"> 66 </td><td align="right"> 514,250 </td></tr> I need to get the number 48,303 and put it in a label, get 66 and put it in another label, then get 514,250 and put it in another label.. If anyone can figure this out it will help me alot because Ive been trying to do it for a long time now. Thanks. Quote
michael_hk Posted February 2, 2005 Posted February 2, 2005 I will use regular expression to extract the info, but the problem is when the layout (html) changes, the code won't work. Quote There is no spoon. <<The Matrix>>
Lanc1988 Posted February 2, 2005 Author Posted February 2, 2005 the only html that changes is those numbers.. and i have never used regular expressions before, so if someone could post the code I could use to get those 3 numbers from that code, then I could use it as a guide to get all of the other things I need from the rest of the html. Quote
donnacha Posted February 2, 2005 Posted February 2, 2005 Can you just read it as an XML file and access the data as parameters Quote Hamlet
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.