Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a very long string (an HTML document).
I want to replace all instances of a substring for which I know the first few characters and the end character, but the middle part of the substring can vary in both length and additional characters. For example, if I want to replace each of the following using the Replace function and wildcards: <td class="dkbluelt" with <td <td valign="top" bgcolor=#99cbe5" align="left" with <td I have built a for loop using Instr and Mid functions, but it takes a long time to run. Is there any way to use the replace function in VBA using wildcards? for example: Result = Replace(MyLongString, "<td*", "<td") Thanks for any suggestions. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Use a wildcard within edit/replace | Excel Discussion (Misc queries) | |||
Wildcard in the Replace function | Excel Discussion (Misc queries) | |||
Use of Wildcard characters with replace | Excel Discussion (Misc queries) | |||
Doing a replace with a wildcard charcter | Excel Discussion (Misc queries) | |||
replace using wildcard, or else | Excel Discussion (Misc queries) |