Make Dll available for all applications

Hi,

when compiling Windows applications (Windows 10), some DLLs (shellx64.dll, crypto.dll) are created, which only have to be present in a subfolder of the same name (%Appname% Libs). I can not copy it to c: \ Windows or c: \ windows \ system32 either, they are not found there. I also tried to register them with regsvr32, without success. Can not they be centrally available for all applications?

Thanks
(Translated by google :slight_smile: )

common libs folder for multiple apps (Windows)

This may help you.

Thanks.
But all the apps must be in the same folder (?).

I would like to save the dlls centrally (for example, under c: \ windows \ …) and save the apps everywhere.

This is a bad idea as each version of Xojo may use different dll’s with the same name and putting a single copy in a central place will cause “DLL hell” as they may not be the correct one - depending on what version of Xojo you used to compile the application. If you leave them next to the application, where they are currently, you won’t have this problem.

I understand that. But if I use the same xojo version, is there any way to save dll’s like shellx64 or cryopto to a central location?

If you are using the same edition of Xojo and making a number of apps, the safest way of doing what you want would be to put all your exe’s next to each other. When you create your installers for your separate apps, have them install into a common folder (like you company name) inside Program Files, all your apps will the sit side by side and share the dll’s from inside that folder.

Ok, thanks a lot to you all.
For me is that a workaround and not that what I wanted. But it is practicable :slight_smile:

DLLÂ’s from plugins have to be either in Libs or just Libs.

Hi, me again.
What is the best practice in managing DLLs? (here an example for a 64bit application).

Windows 64 bit\test\:
msvcp120.dll
msvcp140.dll
msvcr120.dll
Shellx64.dll
test.exe
vccorlib140.dll
vcruntime140.dll
XojoGUIFramework64.dll

Windows 64 bit\test\test Libs:
Cryptox64.dll
Internet Encodingsx64.dll
Shellx64.dll

All DLL’s copied to “test lib” unfortunately did not work. With many programs in a folder like you company name) , as already suggested, you quickly lose track.
I can copy all the dll to a lib folder and expand the system Environment variable with this folder. But I’m not sure if that makes sense.

The DLLs that weÂ’re in the root directory with the app need to stay there. Basically, the folder structure that was produced is what the app needs. Now, the ones that are in the root directory may have been installed as part of a Windows Update, or you can add them to your installer.

I would like to have them away from the root directory of the apps, so that multiple apps can be stored clearly in a folder

My idea:

C:\ Program Files\myCompany\Lib
X.dll (for app1)
Y.dll (for app2)
Z.dll (for app3)

C:\ Program Files\myCompany\
app1
app2
app3

C:\Program Files\myCompany\DLL
msvcp120.dll
msvcp140.dll
msvcr120.dll
Shellx64.dll
vccorlib140.dll
vcruntime140.dll
XojoGUIFramework64.dll

And then expand the system Environment variable with „C:\Program Files\myCompany\DLL“

That’s how it works for me, but I’m not sure if there’s a better way. (I’m new with Xojo on Windows, previously programmed with AutoIt)

If the environment variable change works then its a ok method.

However, looking through most of the apps I have installed they are all littered with dll’s and exe’s sitting next to each other. Is there a particular reason why you want a clean folder? i.e. you want people to navigate to your folder and use command line tools?

Other than that, I don’t really see the point for a user to go into your folder and see its “messy”.

If you do want them to navigate to your folder you could always create a “clean” folder with your installer then add .bat files inside that folder that link to your exe’s so you end up with a clean folder of executable command line tools.

If you do want them to navigate to your folder you could always create a “clean” folder with your installer then add .bat…

That is a nice idea, thank you very much!