I have a (big) problem with exporting to DXF. I've been testing some approach of using TsgCADtoDXF (in C++ Builder 2009), but some kinds of DXF's are not exported. Exporting to DXF is the last stage of my project and everything else work properly. I have a paintbox:
- Code: Select all
TSGDrawingNavigator *FsgPaintBox;
__property TSGDrawingNavigator* sgPaintBox = {read=FsgPaintBox};
where DXF's are drawn (and I don't have any problem with this); and one global object, where all drawn DXF's are kept:
- Code: Select all
TsgCADImage *vGlobalCADFile;
I've tried to do like this:
- Code: Select all
TsgCADtoDXF * vExpCADfile;
if(sgPaintBox)
{
vExpCADfile = new TsgCADtoDXF((TsgCADImage *)sgPaintBox->Picture->Graphic);
try
{
vExpCADfile->SaveToFile(SaveDialog3->FileName);
ShowMessage(MSG20);
}
__finally
{
delete vExpCADfile;
}
}//if
or like this:
- Code: Select all
TsgCADtoDXF * vExpCADfile;
if(vGlobalCADFile)
{
vExpCADfile = new TsgCADtoDXF(vGlobalCADFile);
try
{
vExpCADfile->SaveToFile(SaveDialog3->FileName);
ShowMessage(MSG20);
}
__finally
{
delete vExpCADfile;
}
}//if
Both approach give me the same effect - some of DXF's on the paint box are not exported (depends on DXF contains - I've read internal structure of these DXF's and suppose that problem could lie in INSERT's).
I've spent on this problem some time - even tried to write my own exporting function basing on TsgDXFExport - and the result is still unsatisfying to me.
I'm asking for help.
Best regards,
Mariusz Hyzorek
