I'm getting an exception when calling CreateImageByExtension
CADImport.CADImage cadImage = CADImage.CreateImageByExtension(filename);
System.InvalidOperationException: 'Cross-thread operation not valid: Control 'MainForm' accessed from a thread other than the thread it was created on.'
I'm calling CreateImageByExtension in a Task returned from an async method. I have a MainForm in my project, but I also see the text "MainForm" in CadImport.xml.
Any ideas?
CreateImageByExtension Exception
Moderators: SDS, support, admin
-
- Posts: 5
- Joined: 19 Sep 2016, 19:51
Re: CreateImageByExtension Exception
I forgot to register my license for CAD.NET. CAD import was trying to show the registration dialog and caused a cross-threading issue. This should be fixed in CAD.NET, though. The demo version should support asynchronous code.
Re: CreateImageByExtension Exception
Hello,
Could you please create a small project which reproduces this issue and send it to the Technical Support e-mail for investigation?
Mikhail
Could you please create a small project which reproduces this issue and send it to the Technical Support e-mail for investigation?
Mikhail
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support
Chat support on Skype: cadsofttools.support