I understand. That's what I did for the test, and the problem disappeared.
But. I ask another.
For example, to work with the library System.Data.SQLite (
http://system.data.sqlite.org), I use the following folder structure:
Code: Select all
File name Size
--------------------------- ---------------
ceShell.View.Win.exe 549,888
System.Data.SQLite.dll 253,440
System.Data.SQLite.Linq.dll 182,784
x64\
SQLite.Interop.dll 946,688
x86\
SQLite.Interop.dll 700,928
total files 5 total size 2,633,728
And in this case, at the start on 32-bit Windows automatically uses x86 version of the library, and at the start on 64-bit Windows, used x64 version.
In this case the application (ceShell.View.Win.exe) itself compiled as AnyCPU.
See docs:
http://system.data.sqlite.org/index.htm ... loads.wiki
Using Native Library Pre-Loading
The final step is to identify the target processor architecture on both the development and customer machines. Generally, x86 binaries will work on an x64 machine running Windows (using WoW64). However, there is a problem when using managed code. If the executable that starts the process consists entirely of managed code, it will run with the native processor architecture of the machine, which will be x64 on an x64 machine. Later on, this will cause assemblies containing any native code compiled for x86 (e.g. the "System.Data.SQLite.dll" mixed-mode assembly, the "SQLite.Interop.dll" native interop assembly, or the "sqlite3.dll" native library) to fail to load, typically resulting in a BadImageFormatException being thrown.
If the development and customer machines may have different processor architectures, more than one binary package may be required. For this situation, using the native library pre-loading feature is highly recommended. It is available as of version 1.0.80.0 and enabled by default. In order to take advantage of this feature, the separate managed and interop assemblies must be used with XCOPY deployment (i.e. this feature is not supported by the mixed-mode assembly, nor when the assembly is deployed to the global assembly cache), resulting in an application deployment that looks something like this:
\App.exe (optional, managed-only application executable assembly)
\App.dll (optional, managed-only application library assembly)
\System.Data.SQLite.dll (required, managed-only core assembly)
\System.Data.SQLite.Linq.dll (optional, managed-only LINQ assembly)
\x86\SQLite.Interop.dll (required, x86 native interop assembly)
\x64\SQLite.Interop.dll (required, x64 native interop assembly)
...
I need AnyCPU application.
How to do the same with Devart component???
Please show an example based on my application.