部署到客户服务器后,现场反馈打不开软件
1.查看事件查看器报错
Description: A .NET application failed. Application: DataCollectionClient.exe Path: C:\Users\Administrator\Desktop\***.exe Message: The application to execute does not exist: 'C:\Users\Administrator\Desktop\***.dll'.
后面查看桌面程序,发现不是快捷方式,是exe,但是目前打包exe是带支持dll的,找到程序包所在实际目录,重新启动,仍未打开 ,再次查看事件查看器
2.事件查看器报错
Description: A .NET application failed. Application: DataCollectionClient.exe Path: C:\Users\Administrator\Desktop\mes\DataCollectionClient_202505211742\DataCollectionClient.exe Message: Failed to load the dll from [C:\Program Files\dotnet\host\fxr\6.0.36\hostfxr.dll], HRESULT: 0x80070057 The library hostfxr.dll was found, but loading it from C:\Program Files\dotnet\host\fxr\6.0.36\hostfxr.dll failed - Installing .NET prerequisites might help resolve this problem. https://go.microsoft.com/fwlink/?linkid=798306
根据事件查看器报错,打开链接,找到我windows7对应环境及安装包,安装后重启

3.注意事项
在我排查前,电脑已安装对应 net环境,所以安装其他补丁后成功,未安装环境的注意需先安装对应net环境