Last post May 14, 2020 12:41 AM by thartshorn
May 12, 2020 05:21 PM|thartshorn|LINK
We have a basic Windows Forms application, which acts as a shell around a CefSharp browser and is distributed to our clients via ClickOnce deployment.
Generally we haven't had many issues with people installing this application, as most of our clients have been upgrading from a previous .Net desktop application. However some of our newer clients have been purchasing brand new computers with a clean install
of Windows 10, and in those cases the application fails to start unless we install a copy of Visual Studio, and then remove it to save disk space.
The error we see is this:
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.IO.FileNotFoundException
Followed by a standard appcrash report:
Faulting application name: App POS.exe, version: 184.108.40.206, time stamp: 0x5e87294b
Faulting module name: KERNELBASE.dll, version: 10.0.18362.418, time stamp: 0x2b181c2c
Exception code: 0xe0434352
Fault offset: 0x00113572
Faulting process id: 0x17d4
Faulting application start time: 0x01d6280dfdaf68fd
Faulting application path: C:\...\App POS.exe
Faulting module path: C:\Windows\System32\KERNELBASE.dll
It seems like the clickonce launcher is not pointing to the correct application packages location, since it can't even find the entry point in Program.Main().
The files and manifests all install correctly into the AppData directory, identical to what we see on other machines. No changes have to be made after installing VS. The application just runs where it had failed before.
Is there a known way around this so we do not have to continue to download a very large and unnecessary IDE onto our clients' business machines? Does clickonce have some hidden .net/sdk dependencies that we're missing?
May 13, 2020 07:47 PM|PatriceSc|LINK
According to https://github.com/cefsharp/CefSharp/issues/1185 you might be able to fix this by installed redistributable files.
May 14, 2020 12:41 AM|thartshorn|LINK
Thanks, you pointed me in the right direction. It was the dependency on the VS2012 visual c++ redistributable that was missing.
We had this listed as a prerequisite in ClickOnce, but it turns out Microsoft broke the built-in download links for those packages, and doesn't seem to have any plans to fix it. See here for more details: https://developercommunity.visualstudio.com/content/problem/586416/clickonce-bootstrapper-system-no-longer-works-for.html
Our solution for now is going to have to be sending our clients a link to download the 2012 redistributable prior to installing our application proper. As wonky as that is.