.net - Not getting line number of exception in dot net app -


I have to be a data migration app in .NET 3.0 VS2008.

I want to deploy the debug mode and copy the PDB file to run the server.

I get an exception but no line number.

In this way I display an exception

Why the exception is not a line number

malcolm

  string msg = String.Format ("{0} {1} {2}", ex.Message, ex.StackTrace.ToString (), ex.Source.ToString ()); If (ex.InnerException! = Null) msg ​​= = string.Format ("{0}", ex.InnerException.ToString ()); Return message;  

If you are not getting a line number, either

a) .NET runtime is determining that .pdb does not match assembly (compiled with old, customizable, etc.)

or

b) The assembly is running from a directory that is Pdb is different from one (for example, a Windows service runs under% WINDOWS% \ System32)

This first possibility is not applicable to you, is it a Windows service or what Changing execution directory?

In any event, you should be able to use AppDomain


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -