Typically, an architecture error, when dealing with the LEAD Multimedia toolkit, is due to using x64 architecture with x86 libraries, or vice versa.
First, decide if the project is going to be x86 or x64.
In Visual Studio you can set this here:
Or by altering this in the "Configuration Manager" the exception references.
To find this:
>> GoTo Build
>> Configuration Manager...
Then check the "Active solution platform" and "Platform" match and are the same architecture you are developing for.
Once set, you will want to:
>> _rightClick on the project
>> GoTo Properties
>> Once properties is open, select the Build tab
>> then make sure the build path is set to the correct location
if not, you can select [Browse...] to find the correct file path
for x64 you will want to point to:
C:\LEADTOOLS22\Bin\DotNet4\x64
for x86 you will want to point to:
C:\LEADTOOLS22\Bin\DotNet4\Win32
Additionally, sometimes libraries can inadvertently be overwritten when running an application pointing to the wrong architecture, so you should check the specified Leadtools.Multimedia.dll to make sure that it is still the same architecture as the file folder you are pointing to.
To make sure that the Leadtools.Multimedia.dll has not been overwritten:
>> GoTo the corresponding architecture file folder
x64
C:\LEADTOOLS22\Bin\DotNet4\x64
x86
C:\LEADTOOLS22\Bin\DotNet4\Win32
>> Scroll to the Leadtools.Multimedia.dll
>> _rightClick on the dll
>> GoTo Properties
>> GoTo the Details tab
>> check to make sure the architecture listed matches the file folder that you are pointing to
If this is the incorrect architecture, you will want to replace the Leadtools.Multimedia.dll with the correct one.
For version 22 users, this can be done by reinstalling the SDK, which will replace all files.
For previous version users, if you do not have a copy of the file folder on hand that has not been altered, you can obtain a download link for an older version by submitting a request via email to our Support Department.
support@leadtools.com Please be sure to include the developer key being used with the request, so the Support Agent handling your request can validate a purchased license for that archived version of the SDK exists.
Chris Thompson
Developer Support Engineer
LEAD Technologies, Inc.