Regex help

Tech-Archive recommends: Fix windows errors by optimizing your registry



Hello!

I have a file with following htmlt tags:

.....can be anything before....
<div id="SomeConfig">
some text, can be anything here, also any tag
</div>
.....can be anything after......

I want to "cut" out the div which has an id attribute with config in its's
value. In the above sample
this would be:
<div id="SomeConfig">
some text, can be anything here, also any tag
</div>

I try with this but it does not work:

Dim re As Regex = New Regex("(<div id=.*?config.*?div>)",
RegexOptions.IgnoreCase)
Dim m As Match = re.Match(Text)
Dim s As String = m.Value()

Any suggestions?

Marius


.



Relevant Pages

  • Re: Additional TreeView Property?
    ... information including what you are currently putting in the tag and use the ... Dim iFile As Integer ... Dim FileName As String ...
    (microsoft.public.vb.general.discussion)
  • Re: VBA: Selectively Deleting Notes in a PowerPoint PPT
    ... tag that with a PPT tag. ... Dim oSl As Slide ... Dim oSh as Shape ... For Each oSl In ActivePresentation.Slides ...
    (microsoft.public.powerpoint)
  • Re: shorts and longs
    ... aren't all TIFF IFD entries and tag values stored as unsigned values? ... so, when i Dim m_Compression as Integer and the return value is 32773, i get ... > as a long which is what you store in your application. ... > Dim TempWord As Integer ...
    (microsoft.public.vb.general.discussion)
  • Re: Update and Insert problems in ListView
    ... I created a ListView with a LinqDataSource and a DataPager. ... Protected Sub Page_Init(ByVal sender As Object, ... Dim tag As Tag = CType ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Basic Tags - Please Help
    ... ' Searches for tags and changes the tag to text then deletes the tag.. ... ' This sub will change a tag to text and delete the tag. ... Dim element As New MbeElement ... Dim filePos As Long ...
    (comp.cad.microstation.programmer)