MSIX 驗證和疑難排解MSIX Validation and Troubleshooting

雖然 MSIX 有 99% 成功安裝率,但有時您需要能夠針對安裝問題進行疑難排解。Though MSIX has a 99% successful install rate, sometimes you need to be able to trouble shoot an installation.

了解應用程式Know the application

了解您要安裝的應用程式及其運作方式,對於疑難排解使用者體驗大有幫助。Understanding the application that you are installing and how it works can go a long way to troubleshooting the user experience. 例如,應用程式是否有可能造成問題的某些限制?For example, does the application have certain limitations that could be causing the issues? 使用者是否可以存取應用程式所需的資源?Does the user have access to the resources needed by the application? 應用程式是否有相依性,而目前的作業系統不符合此條件?Were there dependencies the application had, that were not met by the current operating system?

測試您的應用程式Test your application

在部署您的應用程式之前,請確定已測試過應用程式。Before deploying your application, make sure you have tested your application. Windows SDK 提供一種工具,即 Windows 應用程式認證套件,可以在發佈應用程式之前識別出常見的問題。The Windows SDK provides a tool, the Windows App Certification kit that can identify common issues before publication.
若要安裝最新的 Windows SDK,請前往這裡To install the latest Windows SDK, go here. 若要深入了解 Windows 應用程式認證套件,請參閱 Windows 應用程式認證套件To learn more about the Windows App Certification Kit, see Windows App Certification Kit

小眾測試您的應用程式Flight your application

另一個在初期發現問題的絕佳方法,就是小眾測試您的應用程式。Another great way to catch issues early is to flight your applications. 如果您要透過 Windows 市集或商務用 Microsoft Store 進行部署,則可以使用套件正式發行前小眾測試版,將您的應用程式部署至個人子集,以進行其他實際測試。If you are deploying through the Windows store or Microsoft Store for Business, you can use package flights to deploy your application to a subset of individuals to get additional real world testing.
若要深入瞭解小眾測試,請參閱套件小眾測試To learn more about flighting, see Package flighting.

裝置入口網站和偵錯Device Portal and Debugging

有時候,您必須在使用者的環境中與應用程式互動,才能充分了解問題。Sometimes it is necessary to interact with the application in the user's environment to adequately understand the issue. Windows 提供功能強大的工具,即裝置入口網站桌面,可讓您連線到裝置,並在遠端與應用程式互動。Windows provides a powerful tool, the Device Portal Desktop which will allow you to connect to the device and interact with the application remotely.
若要深入了解裝置入口網站,請參閱裝置入口網站桌面To learn more about Device Portal, see Device Portal Desktop. 若要深入了解如何偵錯 MSIX 套件,請參閱執行、偵錯及測試封裝的傳統型應用程式To learn more about Debugging MSIX packages, see Run, debug, and test a packaged desktop application.

安裝問題Installation issues

當安裝發生問題時,您可以調查 AppInstaller 所提供的成品。When there are issues with the installation, you can investigate the artifacts provided by AppInstaller. 首先,AppInstaller 會提供錯誤碼失敗。First, AppInstaller provides error code failures. 如果任何失敗的錯誤碼不足以判斷錯誤的原因,AppInstaller 也會記錄事件檢視器的所有互動。If the error code for any failure is not sufficient to determine what is wrong, the AppInstaller also logs all interactions to the Event Viewer. 您會在這裡找到記錄檔:應用程式及服務記錄檔->Microsoft->Windows->AppxDeployment-Server.You will find the logs here: Application and Services Logs->Microsoft->Windows->AppxDeployment-Server.

您可以使用事件檢視器或 Powershell 來存取這些事件。You can use the Event Viewer or Powershell to access those events. 若要深入了解如何檢視事件,請參閱針對 Windows 應用程式的封裝、部署和查詢進行疑難排解To learn more about how to view the events, see Troubleshooting packaging, deployment, and query of Windows apps.

若要深入了解如何針對 AppInstaller 進行疑難排解,請參閱針對 Appinstaller 問題進行疑難排解To learn more about AppInstaller troubleshooting, see Troubleshoot Appinstaller Issues.

接下來的步驟Next steps

有任何問題嗎?Have questions? 請在 Stack Overflow 上發問。Ask us on Stack Overflow. 我們的團隊會監視這些標籤Our team monitors these tags. 您也可以在這裡發問。You can also ask us here.