M
Matt
I have a problem and I am looking for suggestions. Here is the situation:
I am writing a VB.NET app to convert a string into a markup language used in
a program we have at my company. The languange handles CrLf's very stragly.
It doesn't ignore them like HTML. It will read and print them when there
are two or more in a row, but it ignores a single CRLF. To do a single line
break, you need to use the command .br; however, two CRLF's register as two
line breaks. That's right. I said two. Oh, just to make things a little
more challenging, replacing every CRLF with a .br doesn't work. The app
only reads the first .br and ignores the rest..
I can't say much for the markup languange , but it is what I have to work
with. Here is what I need to do when I parse the string:
I need to replace a single CRLF with a .br.
I need to leave two or more CRLFs in a row the way they are.
I am looking for a regular expression that would accomplish this, but code
that does the same thing would work too. In other words, any suggestions
would be appreciated.
Thanks,
Matt
I am writing a VB.NET app to convert a string into a markup language used in
a program we have at my company. The languange handles CrLf's very stragly.
It doesn't ignore them like HTML. It will read and print them when there
are two or more in a row, but it ignores a single CRLF. To do a single line
break, you need to use the command .br; however, two CRLF's register as two
line breaks. That's right. I said two. Oh, just to make things a little
more challenging, replacing every CRLF with a .br doesn't work. The app
only reads the first .br and ignores the rest..
I can't say much for the markup languange , but it is what I have to work
with. Here is what I need to do when I parse the string:
I need to replace a single CRLF with a .br.
I need to leave two or more CRLFs in a row the way they are.
I am looking for a regular expression that would accomplish this, but code
that does the same thing would work too. In other words, any suggestions
would be appreciated.
Thanks,
Matt