API Reference > OdDb Classes > OdDbDatabase Class > OdDbDatabase Methods > writeFile Method > OdDbDatabase::writeFile Method (OdString&, OdDb::SaveType, OdDb::DwgVersion, bool, int)
OdDbDatabase::writeFile Method (OdString&, OdDb::SaveType, OdDb::DwgVersion, bool, int)
Syntax
C++
void writeFile(const OdString& filename, OdDb::SaveType fileType, OdDb::DwgVersion fileVersion, bool saveThumbnailImage = false, int dxfPrecision = 16);
Parameters 
Description 
const OdString& filename 
[in] Name of the file to which the data is to be written.  
OdDb::SaveType fileType 
[in] File type.  
OdDb::DwgVersion fileVersion 
[in] File version.  
bool saveThumbnailImage = false 
[in] Controls the saving of a thumbnail image to the file.  
int dxfPrecision = 16 
[in] DXF file decimal digits precision. [0 .. 16]. 

Writes the contents of this database object to the specified output file. 

 

Parameter fileType must be one of the following: 

 

Name 
Value 
Description 
OdDb::kDwg 
.dwg file. 
OdDb::kDxf 
.dxf file. 
OdDb::kDxb 
Binary .dxf file. 

 

fileVersion must be one of the following: 

 

OdDb::kDwg? 
Name 
Value 
Description 
OdDb::vAC09 
11 
Release 9 
OdDb::vAC10 
13 
Release 10 
OdDb::vAC12 
16 
Release 11-12 
OdDb::vAC13 
19 
Release 13 
OdDb::vAC14 
21 
Release 14 
OdDb::vAC15 
23 
2000-2002 
OdDb::vAC18 
25 
2004-2006 
OdDb::vAC21 
27 
2007-2009 
OdDb::vAC24 
29 
2010-2012 
OdDb::vAC27 
31 
2013-2016 
Copyright © 2002–2020. Open Design Alliance. All rights reserved.