.NET 2gb Memory Limitation Fix

Most users won’t hit this limit and shouldn’t worry about it until they do. However a handful of our users processing extremely massive surfaces have reported an error message like “System.OutOfMemoryException” and/or “Array dimensions exceeded supported range”.

In the event that this occurs, you will need to make a minor revision to a supplied file with your CAD engine. If you don’t feel comfortable with this type of operation seek help from your IT support. The file to edit is ascii and lives in the CAD engines primary folder. It’s quite small and you can use notepad to edit it.

First backup the file:

Close all sessions of your CAD engine.

Open Windows Explorer and navigate to the CAD engines primary folder, for example in a recent AutoCAD it should be “C:\Program Files\Autodesk\AutoCAD 2019”.

Look for a small file with the same name as the CAD engine, that has a “.config” at the end, like “acad.exe.config”.

Select the .config file, Right Click and choose Copy.

Right click outside the data columns (just before the scroll bar) and choose Paste. This creates a file with a name like “acad.exe – Copy.config” that you can use if needed.

Next modify the file:

Select the original .config file, Right Click and choose Open With > Notepad.

In the <runtime> section add the following on a line of it’s own.
<gcAllowVeryLargeObjects enabled=”true” />