Images disappear

Discuss and ask questions about CAD .NET library.

Moderators: SDS, support, admin

Post Reply
alex7210
Posts: 5
Joined: 10 Aug 2016, 04:43

Images disappear

Post by alex7210 » 22 Oct 2018, 06:36

Hello

I'm using CAD .NET 11, gathter the spatial data and export to DXF file using CADtoDXF class.

When I load the DXF file in AutoCAD, there is no problem.

But I save it as dwg file, all the images in dxf are disconnected and disappear.

I don't know how to solve this problem.

Could you help me?

And I want to know if there is the way to export to dwg format in CAD .NET.

Thank you.

support
Posts: 3253
Joined: 30 Mar 2005, 11:36
Contact:

Re: Images disappear

Post by support » 22 Oct 2018, 14:44

Hello,

The raster images may get lost if they were added to a CAD drawing as IMAGE objects and the image files cannot be located at the file path specified in a corresponding imagedef object.

As for the export to DWG, it is supported starting from version 12.1 by using an additional dynamic link library sgcadexp.dll which comes with CAD .NET and can be found in the following folders:

c:\Users\USER_NAME\Documents\CAD .NET 12\bin\DWGExportLib\Win32\
c:\Users\USER_NAME\Documents\CAD .NET 12\bin\DWGExportLib\Win64\

To export a CADImage object to the DWG format, you need to copy the file sgcadexp.dll to the folder with CADImport.dll and call a static method CADtoDWG.SaveAsDWG. For example:

Code: Select all

public static void SaveCADImageAsDWG(CADImage cadImage, string dwgFilePath)
{
    CADImport.Export.CADtoDWG.SaveAsDWG(cadImage, dwgFilePath);
}
Mikhail
Technical Support E-mail: support@cadsofttools.com
Chat support on Skype: cadsofttools.support

Post Reply