Faulting Error on VCRUNTIME140.dll


Firstly I would like to explain that I am relatively new to XoJo, having not developed anything from scratch, merely supporting / customising an existing application.

I have a client who has a bespoke application which has been compiled using version 2016r4.1

They are in the process of upgrading hardware to Windows 10 machines and have begun seeing faulting errors with VCRUNTIME140.dll when printing.

I am guessing that there is a compatibility issue with the version of the DLL within the compiled Program Libs path, 14.0.23506.0 and the corresponding Windows 10 version.

Can someone please advise if I can just replace this DLL with the newer version? Apologies if that is a stupid question, as I suggested earlier, this issue is a little out of my comfort zone!

I have tried to recompile the application last year but that caused other issues and the client decided they would continue with the version they had as they didn’t have the time to test the full application!

Many thanks for any suggestions!

Kind regards


Hi Steve,

Is the message something like the DLL can’t be found ? I suggest googling for the name of the DLL. For example I have found https://answers.microsoft.com/en-us/windows/forum/windows_10-windows_install-winpc/vcruntime140dll/b1a15b0e-e389-41a3-bc49-f4fc85bac575 In one of the answers you will find:

You need to install the Microsoft Visual C++ 2015 Redistributable Update 3 RC

Searching on my computer I found that this DLL is in a Xojo’s directory., among others. Lots of applications use that DLL, for example Valentina, MS Office, ESET Security, etc.

Are they getting this issue when running the app compiled with 2016r4.1 ? If so try compiling with a a newer version of Xojo.

Hi Giles

Thanks for the response.

As I said in the post, ithe dll is generating a faulting error which means that it is being found! Also, I mentioned that I have previously tried to compile it with a newer version but that then introduces other errors where the code needs changing!

I’m after, if possible, an easier and quicker resolution.

I’ve noticed in the build parameters, there is a switch Include Windows Runtime Dlls, which is currently switched to off! Is that telling the application to use local DLLs?



Hi Steve!

When possible, this should be set to False to allow the system to manage the version of the runtimes installed. When set to True, it includes the runtimes in the app’s build folder for distribution with the executable.

I wouldn’t go replacing DLLs in the system paths. You never know what you might break elsewhere.

1 Like

Yes. And a switch to YES may help in your case. Give it a try.

A quote from https://docs.xojo.com/UserGuide:Windows_Universal_Runtime

Including the DLLs with your App

For situations where you don’t use an installer but your app needs to run on machines without the Universal Runtime, you can include a local copy of the DLLs instead. In the Windows Build Settings you can turn the “Include Windows Runtime DLLs” property to ON (available on the “Advanced” (gear) tab of the Inspector). When you Run or Build with the property on, the 40 or so necessary Universal Runtime DLLs are copied alongside your app executable.

Additionally, when you turn this on a warning dialog appears to remind you that Windows Universal Runtime DLLs installed in the app folder do not get security updates. This is why Microsoft recommends installing the Universal Runtime by either Windows Update or the Visual C++ Redistributable when possible: further updates to it are handled automatically by the standard Windows Update mechanism.

1 Like

Thanks for all the responses, we have decided that the only right fix is to recompile the application using the latest release of XoJo