Note: from Eyeshot v2020, the bitness agnostic code is included in samples custom control project with the name BitnessAgnostic.cs and it is used by the DraftingDemo sample. To enable it, you need to declare the SETUP conditional symbol and set bitness as AnyCPU in the DraftingDemo VStudio project.
The following source code sample demonstrates how to load DWG/DXF files from a .NET application compiled against AnyCPU. It includes the operating system bitness detection, dynamic loading of the Eyeshot x86 or x64 DLL from a separate folder and the instantiation of the ReadAutodesk class using reflection.
Sample: BitnessAgnosticReadDWG_WinForms_v11.
Previous versions of this article: Eyeshot 10, Eyeshot 9, Eyeshot 8
Comments
Hi Matteo, I have tried this v11 program and it still loads okay in x86, but not x64.
I made a quick video to show how I am testing and what I am doing to try and solve the problem - https://1drv.ms/v/s!AhjMss4NTevChYtGO3d4fTnXO5HLIA
I hope I'm doing something wrong... very strange...
Thanks,
Jas
Hi James,
Did you install also Microsoft Visual C++ 2012 Redistributable Package x64 or just Microsoft Visual C++ 2012 Redistributable Package x86?
It could be that the problem.
https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads
I did the VS2017 x64 from the link above.
Does this require VS2012 instead?
Yes, as written here. ;)
Hey... that worked!!
This is what I had to install - https://www.microsoft.com/en-us/download/confirmation.aspx?id=30679
Thanks for the help...
Please sign in to leave a comment.