DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2008

    Question VB Question, How to read from an HTML file?

    In my code, I need to read lines, each one at a time from an HTML file and put the fields of that line in a one Dimensional array.
    the following is a one line example of what's in the HTML file:

    Sphere <tr><td><a href="http://datasheet-web/DS_Archive/Mechanics/gen-00230150001-ds.pdf" target=_blank>00230150001</a></td><td>General Brand</td><td>DIN5401-3-A2</td><td>Ball,Sphere,3Dia,SS,+/-0.05</td><td>Active</td><td>&nbsp;</td><td>&nbsp; </td><td><a href="K:/Pro_stds/Library/All_Parts/BALLS.prt.4" target=_blank>Model</a></td><td>Acceptable</td><td><font color="#00bb00">N/A</font></td><td><font color="#00bb00">Yes</font></td><td>0</td><td>0.13</td></tr>

    My problems is how do I put only the actual fields of that line in the elements of the array? I Just don't need all of the HTML Tags between the fields.

    Thanks In Advance


  2. #2
    Join Date
    May 2008
    Chicago, IL
    Use .Substring(), .Find() .IndexOf(), etc to strip out the tags, and parse the data.
    It's been discussed many times before. Search the forums.
    David CodeGuru Article: Bound Controls are Evil-VB6

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

Similar Threads

  1. VB read file problem
    By bubu1234 in forum VB Classic
    Replies: 1
    Last Post: 01-21-2007, 09:25 PM
  2. VB App read html code
    By Dralion in forum VB Classic
    Replies: 6
    Last Post: 02-01-2006, 04:06 PM
  3. Replies: 1
    Last Post: 10-03-2002, 11:27 AM
  4. How long before the next version??
    By _CAG in forum .NET
    Replies: 146
    Last Post: 08-12-2002, 10:40 PM
  5. Replies: 1
    Last Post: 04-02-2002, 10:45 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.