How to ignore missing DLL errors? (Loader.cpp error)

Hi all,

I have a project that takes a different approach to a problem when you’re on Windows 7/8 as when you’re on Windows 8.1/10.

Windows 8.1+ ships with a DLL that solves this problem, which I’m using.
Windows 7 and 8 do not have this problem and thus do not ship with the DLL.

I am testing for the Windows version and only make reference to the DLL and its functions if I detect Windows 8.1+.

The problem is that simply having a reference to the DLL is enough to throw an error on Windows 7 and 8. I get the Common/Loaders/Loader.cpp “Failed to load library” error at program start.

How can I get the runtime to ignore this error, skip the error message and allow the program to execute?

I assume you’re using declares ?
Use the “soft” keyword for the declares
http://developer.xojo.com/declare

Fantastic, thanks!

Hello, the links points to an index, not to the page
regards

Try https://documentation.xojo.com/api/language/declare.html

that pointed to the old docs
this is the correct one now
https://documentation.xojo.com/api/language/declare.html