I want to get a List(Of String)
of text blocks, however there is a problem:
{ --isso é um bloco;
echo "Aqui tem um } no meio";}
And I would like to get this:
--isso é um bloco;
echo "Aqui tem um } no meio";
but it's coming back to my method:
--isso é um bloco;
echo "Aqui tem um
And just over there, is there any way you can get multiple blocks except when they are within the "..."
characters?
Here is my method code:
Dim tmpBlocks() As String = theFile.Split({"{"}, StringSplitOptions.RemoveEmptyEntries)
Dim Blocks As New List(Of String)
For i As Integer = 0 To tmpBlocks.Length - 1
Blocks.Add(tmpBlocks(i).Split(New [String]() {"}"},
StringSplitOptions.RemoveEmptyEntries)(0))
Next
' Blocks é a variável de cara bloco
Regex and Regular Expressions