3

我刚刚从网站下载了后台工作人员示例以供参考,当我运行应用程序时,它运行没有任何问题。后台任务正常执行,并显示 toast 通知。

但问题是我将目标版本从 Windows Phone 7.1 更改为 Windows Phone 8 后,它没有执行后台任务。它显示错误System.Windows.pdb not loaded

我没有更改项目中的单段代码。我不知道为什么会发生这个错误..请帮助我..

这是我从网站下载的示例。

这是调用堆栈 > System.Windows.ni.dll!MS.Internal.JoltHelper.OnUnhandledException(object sender, System.UnhandledExceptionEventArgs args) Unknown [Native to Managed Transition]
[Managed to Native Transition]
mscorlib.ni.dll!System.Reflection.RuntimeAssembly.nLoad(System.Reflection.AssemblyName fileName, string codeBase, System.Security.Policy.Evidence assemblySecurity, System.Reflection.RuntimeAssembly locationHint, ref System.Threading.StackCrawlMark stackMark, System.IntPtr pPrivHostBinder, bool throwOnFileNotFound, bool forIntrospection, bool suppressSecurityChecks) Unknown mscorlib.ni.dll!System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(System.Reflection.AssemblyName assemblyRef, System.Security.Policy.Evidence assemblySecurity, System.Reflection.RuntimeAssembly reqAssembly, ref System.Threading.StackCrawlMark stackMark, System.IntPtr pPrivHostBinder, bool throwOnFileNotFound, bool forIntrospection, bool suppressSecurityChecks) Unknown mscorlib.ni.dll!System.Reflection.RuntimeAssembly.InternalLoad(string assemblyString, System.Security.Policy.Evidence assemblySecurity, ref System.Threading.StackCrawlMark stackMark, System.IntPtr pPrivHostBinder, bool forIntrospection) Unknown mscorlib.ni.dll!System.Reflection.RuntimeAssembly.InternalLoad(string assemblyString, System.Security.Policy.Evidence assemblySecurity, ref System.Threading.StackCrawlMark stackMark, bool forIntrospection) Unknown mscorlib.ni.dll!System.Reflection.Assembly.Load(string assemblyString) Unknown Microsoft.Phone.ni.dll!Microsoft.Phone.BackgroundAgentActivator.LoadEntryPointAssembly(string assemblyName) Unknown Microsoft.Phone.ni.dll!Microsoft.Phone.BackgroundAgentActivator.LoadAgent(string assemblyName, string typeName) Unknown Microsoft.Phone.ni.dll!Microsoft.Phone.BackgroundAgentActivator.Microsoft.Phone.IBackgroundAgentActivator.CreateBackgroundAgent(string assembly, string typeinfo) Unknown Microsoft.Phone.ni.dll!Microsoft.Phone.BackgroundAgentDispatcher.AgentRequest.Invoke() Unknown Microsoft.Phone.ni.dll!Microsoft.Phone.BackgroundAgentDispatcher.InvocationThread() Unknown mscorlib.ni.dll!System.Threading.ThreadHelper.ThreadStart_Context(object state) Unknown mscorlib.ni.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx) Unknown mscorlib.ni.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx) Unknown mscorlib.ni.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state) Unknown mscorlib.ni.dll!System.Threading.ThreadHelper.ThreadStart() Unknown [Native to Managed Transition]

4

1 回答 1

0

pdb 文件是一个符号文件,用于在调试时单步执行代码。

我不确定为什么在调试时要进入 system.windows ...您可能需要查看工具-> 选项并检查您是否没有尝试进入 Microsoft 代码。

问题是您遇到了异常,而调试器正在尝试获取它,但它正在满足该异常。

由于您无法更改它,因此进入该程序集毫无意义-但是也许您想为此而寻找。我个人不会打扰;p

于 2013-05-23T13:12:34.647 回答