Posted on: 11/20/2014 7:25:11 PM | Views : 449

Hi All,
I have to split the string based on the following criteria:
[1] this is first string <Line feed> [2] This is second string <Line feed> [3] This is a Third string that is pretty long<Line feed> I want to put, this to be together [4] This is the third part. I want the below extracted string in an array
[1] this is first string [2] This is second string [3] This is a Third string that is pretty long I want to put, this to be together [4] This is the third part. so I want the
arr[0]=1 ad arr[1]=this is first string and so  on
I have this regular expression from my previous post. It works fine when there are no square brackets around the number, but once I have the square brackets, it parses the above string with the number.
^((\d+)\.)?(.*?)$ Thanks.
...

Go to the complete details ...