I am very thankful to both Thomas and Stan for the suggestions. Let me explain what I am trying to achieve. I have a
word document.
I convert this into a text file. I store the contents of the text file in a string. I need to identify the subheadings such as SUMMARY in case this is a resume which has SUMMARY as one of the subheadings. Once 2 consecutive sections are identified, I will be able to process the contents in between these sections. To do that I create a regular
expression such that I can identify a section.
But, the regular expression to identify the SUMMARY section does not seem to work. I am not sure if the regular expression is right. Is this the right way I am approaching?
Here is the sample code ...