【发布】微软应用商店第三次提交失败【问题已经解决】
【问题】
第二修改提交 ,继续失败。问题如下:
The product crashes when selecting 日语五十音图表, 练习模式 or 挑战模式. The issue was observed on multiple devices running Windows build 22621.1105
Observed On: Dell Latitude 5502, Microsoft surface laptop Go
Tested On: Dell Latitude 5502, Microsoft surface laptop Go
Tip: A Windows product may run flawlessly during development and testing, but after submitting it for certification testing, the product may crash or perform unexpectedly. Along these same lines, your product may not perform as expected after publication. You can contact Developer Support at http://aka.ms/storesupport if you need assistance with troubleshooting.
Observed On: Dell Latitude 5502, Microsoft surface laptop Go
Tested On: Dell Latitude 5502, Microsoft surface laptop Go
Tip: A Windows product may run flawlessly during development and testing, but after submitting it for certification testing, the product may crash or perform unexpectedly. Along these same lines, your product may not perform as expected after publication. You can contact Developer Support at http://aka.ms/storesupport if you need assistance with troubleshooting.
Tested devices: Dell Latitude 7480
【解决方案】
【解决方式 一】
我在程序中采用”System.Environment.CurrentDirectory“方式获取当前目录,当程序打包成.exe|.msi 安装后软件运行能准确的获取资源。
而当我把程序打包成成.msix 程序包是,.msix是沙盒的模式运行,由第三方应用启动的。就无法准确的获取当前程序的当前目录,只能获取沙盒的所在的当前目录。
所有应该把把代码中的”System.Environment.CurrentDirectory“方式获取当前目录,修改成:System.AppDomain.CurrentDomain.BaseDirectory。
【解决方式 二】
软件抛出 没有写入权限的异常。原因是 在把软件打包成.msix 文件时候,采用了默认的安装路径(即 C:\Program Files\ WindowsApps 该文件夹不能不具备写入权限),为了让软件具备写入权限 需要在打包软件安装路径时候,选择在C盘的其他位置。
【解决方式 三】
同时代码中要捕捉 写入异常,如下:
try { iphonogramPocoRepository.SerializerAndSave(voicelessConsonants, @"Resources\CoicelessConsonant.txt"); } catch (Exception etr) { MessageBox.Show(etr.Message+"123"); }
扩展:https://www.cnblogs.com/cdaniu/p/18102960
编程是个人爱好