Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

removing sections of a string 1

Status
Not open for further replies.

biry

Technical User
Nov 5, 2004
127
0
0
CA
Hi, i have a string with html code, the begining of the string is as follows:

Code:
<html><head><title>Testing</title></head><body><center>Items 1 - 80<br>
<table>
<tr BGCOLOR="#D6D6D6">
<th align="left" nowrap="nowrap" width="4%">Form</th>
<th align="left" nowrap="nowrap" width="4%">Formats</th>
<th align="left" width="20%">Description</th>
<th align="left" nowrap="nowrap" width="4%">Accepted</th>
<th align="left" nowrap="nowrap" width="4%">Filing Date</th>
</tr>

i would like to eliminate the following lines from the string:
<th align="left" nowrap="nowrap" width="4%">Formats</th>

and
<th align="left" nowrap="nowrap" width="4%">Accepted</th>

How can i accomplish this?

thanks
 
If this is one large string, and the text to temove is always the same, you can use the Replace() function:

StringVar = Replace(StringVar, "<th align=""left"" nowrap=""nowrap"" width=""4%"">Formats</th>", "")

StringVar = Replace(StringVar, "<th align=""left"" nowrap=""nowrap"" width=""4%"">Accepted</th>", "")

I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top