DXF Save version support

I cant seem to set the version to anything other than R12 when I save a dxf file.

I am trying to use DxfOptions.Version = to set the version but I only see R12.

Can the DXF be output to other versions?

@Raider007,
Hello.
Yes, saving from other formats to DXF at the moment is possible only into R12. Saving from the initial DXF preserves version. We work now on the bugfixing/improvements of the quality of export to DXF for all scenarios.

Is it possible to open a 2000 version dxf file and save it as R12 version DXF?

@Raider007

Unfortunately, we have troubles with making this option working too and will look at this in the scope of the ticket described below. Please, attach the example of file you are trying to convert, it could be useful to evaluate the backwards compatibility of different entities between versions.

We are sorry for the confusion.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CADNET-9266

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

Hi Oleksii,

There is no specific file even though I can send you a few DXF/DWG files. I was just asking in general because we are looking for a solution to convert DWG/DXF to R12 DXF files from time to time. Believe it or not, there are still people out there who have CNC machine software that can only open R12 DXF files.

Do you have a timeline for this feature to be added? This year, next year?

1 Like

@Raider007,

Here is the way to export DXF 2000 to DXF R12 via the intermediate DWF format:

string fileName = "some_file.dxf";
string outPath = fileName + ".dxf";

using (CadImage cadImage = (CadImage)Image.Load(fileName))
{
    using (MemoryStream dwfStream = new MemoryStream())
    {
        cadImage.Save(dwfStream, new DwfOptions());

        dwfStream.Seek(0, System.IO.SeekOrigin.Begin);

        using (Image dwf = Aspose.CAD.Image.Load(dwfStream))
        {
            dwf.Save(outPath, new DxfOptions());
        }
    }
}

The direct save to DXF R12 is planned for 23.8 release in August (but I can not guarantee this).
In both cases the result DXF R12 file will be represented as polylines. Unfortunately, we don’t have plans now to implement full support between these versions of the format. We are sorry for the inconvenience.

Thank you so much for your reply. I will wait for the 23.8 version and give it a try.

1 Like

Hi, do you know if the direct save to R12 has been added to this version?

image001.jpg (162 KB)

@Raider007,
Hello,
please, try to use this option with the latest 23.8 release:

image.Save(outR12fileName, new DxfOptions() { Version = DxfOutputVersion.R12 });

Ok great I will try that. Thank you.

1 Like