How to get specific text from file

Following code is fetching specific words from a text file.
 
Here is our Main method
  1. private static void Main(string[] args)   
  2. {  
  3.     //Set the actual path from your system    
  4.     const string filePath = @"container/myComments.txt";  
  5.     const string singleline = "SingleLine";  
  6.     const string multiline = "MultiLine";  
  7.     var comemnts = new Comment();  
  8.   
  9.     Console.WriteLine("Single Line Comments : ");  
  10.     Console.WriteLine(comemnts.GetCommentsInUpperCase(filePath, singleline));  
  11.   
  12.     Console.WriteLine("MultiLine Comments : ");  
  13.     Console.WriteLine(comemnts.GetCommentsInUpperCase(filePath, multiline));  
  14.   
  15.     // Suspend the screen.    
  16.     Console.ReadLine();  
  17. }  
Our Comment class:
  1. public class Comment  
  2. {  
  3.     public String GetCommentsInUpperCase(String filePath, String@  
  4.     case)   
  5.     {  
  6.         string line;  
  7.         var retunComments = String.Empty;  
  8.         var sbSingleLine = new StringBuilder();  
  9.         var sbMultiLine = new StringBuilder();  
  10.         //Create streamReader object    
  11.         var file = new StreamReader(filePath);  
  12.   
  13.         //Read line by line    
  14.         while ((line = file.ReadLine()) != null)   
  15.         {  
  16.             line = line.TrimStart();  
  17.   
  18.             switch (@  
  19.             case)   
  20.             {  
  21.                 case "SingleLine":  
  22.                     if (line.Contains("//")) //for singleline comment    
  23.                     {  
  24.                         //Get rest part of line in uppercase and move the counter to next line    
  25.                         var strLine = line.Replace("//""");  
  26.                         sbSingleLine.AppendLine(strLine.ToUpper());  
  27.                         //counter++;    
  28.                     }  
  29.   
  30.                     retunComments = sbSingleLine.ToString();  
  31.                     break;  
  32.   
  33.                 case "MultiLine":  
  34.                     if (line.StartsWith("/*")) //for multiple line comments    
  35.                     {  
  36.                         var strLine = line.Replace("/*""");  
  37.   
  38.                         sbMultiLine.AppendLine(strLine.ToUpper());  
  39.                     }  
  40.   
  41.                     if (line.StartsWith("*") || line.EndsWith("*/")) //for between and termination of multiple line comments    
  42.                     {  
  43.                         var strLine = line.TrimStart('*').Replace("*/""");  
  44.   
  45.                         sbMultiLine.AppendLine(strLine.ToUpper());  
  46.                     }  
  47.   
  48.   
  49.                     retunComments = sbMultiLine.ToString();  
  50.                     break;  
  51.                 default:  
  52.                     //by default line which does not fall in above cases may be treated as a part of multiple comment    
  53.                     //in this case I supposed that this is a part of multiline comment    
  54.                     sbMultiLine.AppendLine(line.TrimStart('*').ToUpper());  
  55.                     break;  
  56.             }  
  57.         }  
  58.   
  59.         file.Close();  
  60.   
  61.         return retunComments;  
  62.     }  
  63. }  
Download the attached code and enjoy!