AnsweredAssumed Answered

SolidWorks crash without exception - .NET Add-In

Question asked by Andrew Johnson on Sep 6, 2017
Latest reply on Sep 8, 2017 by Jacob Corder

When I execute a particular command in my .NET Add-In, sometimes (depending on the document) SolidWorks crashes without any .NET Exception thrown from my code. It goes straight to the Windows Error Reporting dialog. When I choose 'Debug' on that dialog, I am able to get some very limited information about the crash in Visual Studio.

 

Unhandled exception at 0x00007FFA3D63775F (ntdll.dll) in SLDWORKS.exe: 0xC0000374: A heap has been corrupted (parameters: 0x00007FFA3D6986B0).

 

I'm not managing memory explicitly, so I have no reason to believe that my code is the direct cause. I have stepped line-by-line through my code in Visual Studio to at least find at which line of code the crash occurs, but that is not consistent. It crashes at different points in the code, which also indicates to me that the Add-In is not the root cause. Maybe it's a memory management issue within SolidWorks itself? Anyone have an idea where I should take things from here?

 

Thanks

Outcomes