title: Stack Trace not return lineNo and Filename
body: <p>i am cathing exceptions to writing but it's return null for fileName and return 0 for line number. i open any other project and it runs succesfully. i think it's related with debug settings how can i change my project setting to response my code ? </p>
  
  <pre><code>public static void WriteUnexpectedErrors(Exception ex)
  {
      StackTrace trace = new StackTrace(ex, true);
      string fileName = trace.GetFrame(0).GetFileName();
      int lineNo = trace.GetFrame(0).GetFileLineNumber();
  }
  </code></pre>
  
  <p>This code came some result  but at above code not working especially GetFrame(0).GetFileName();</p>
  
  <pre><code>foreach (var frame in trace.GetFrames())
                  {
                      if (!string.IsNullOrEmpty(frame.GetFileName()))
                      {
                          Console.WriteLine(frame.GetFileName());
                      }
                      if (frame.GetFileLineNumber() &gt; 0)
                      {
                          Console.WriteLine(frame.GetFileLineNumber());
                      }
                  }
  </code></pre>