在正與VS2010中「時拋出」開啓例外打破本地調試點擊一次應用程序的情況下,我遇到了以下錯誤:存儲元數據「CurrentBind」無效。錯誤
Deployment Exception: "Store metadata "CurrentBind" is not valid."
at System.Deployment.Application.ComponentStore.GetPropertyString(DefinitionAppId appId, String propName)
當我執行下面的一行代碼:
if (System.Deployment.Application.ApplicationDeployment.IsNetworkDeployed)
此異常正在被.net代碼捕獲和處理,並且遇到此錯誤後應用程序不會崩潰。不幸的是,這個錯誤是由隨訪:
InvalidDeploymentException: "Application is not installed"
at System.Deployment.Application.ApplicationDeployment..ctor(String fullAppId)
如果我繼續通過例外韋德,我得到另一個錯誤:
SynchronizationLockException: "Object synchronization method was called from an unsynchronized block of code"
at Microsoft.Practices.Unity.SynchronizedLifetimeManager.TryExit()
@ ProvidedContainer.RegisterInstance(LoggerFacade);
最後:
ConfigurationErrorsException: "This element is not currently associated with any context"
at System.Configuration.ConfigurationElement.get_EvaluationContext()
在構造函數的
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")]
public partial class InfrastructureDataServiceClient : System.ServiceModel.ClientBase<Infrastructure.DataServices.IInfrastructureDataService>, Infrastructure.DataServices.IInfrastructureDataService
{
public InfrastructureDataServiceClient() {
}
}
這些錯誤全部由.net框架代碼處理,並且不會影響應用程序,但只要我有選擇打破異常「投擲」,我會繼續經歷這些錯誤,直到我失去耐心並選擇只在未處理的異常時纔打破,此時應用程序將完全加載。
這在過去發生在我身上,當時我不得不徹底重新安裝visual studio,但是之後它運行良好。我寧願不這樣做,因爲它很費時間,我的VS安裝非常自定義。此外,我的同事也沒有遇到同樣的錯誤,所以這告訴我有關於我的環境的獨特之處。
我最近在調試時遇到了視覺工作室掛起,並且不得不殺死devenv進程,這可能會起到一定作用,但很難說,因爲我最近打開了拋出選項的中斷。我已經嘗試刪除suo文件,但沒有任何效果。
我已經安裝了以下插件: ReSharper的,.net反射,團隊資源管理器,TFS電動工具,主題管理器
這是錯誤的。這是一個簡單的調試選項,您需要取消選中。請參閱http://stackoverflow.com/questions/1914531/store-metadata-currentbind-is-not-valid-in-debug-of-clickonce-application – 2012-05-06 23:13:02