几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   DirectDWG (http://www.dimcax.com/hust/forumdisplay.php?f=89)
-   -   【转帖】help, get dwg version problem (http://www.dimcax.com/hust/showthread.php?t=16522)

yang686526 2009-05-05 12:08 PM

【转帖】help, get dwg version problem
 
help, get dwg version problem
help, get dwg version problem
hi guys:
i got a strange problem with the dwg file version. i got the same result of the dwg version(kdhl_1021) using below code, though i changed different version dwg files.
oddbdatabaseptr pdb = exhostappservices::createdatabase(false);
pdb->setretainoriginalthumbnailbitmap(true);
pdb->readfile("d:\\2000.dwg", false, oda::ksharedenyreadwrite);
if (!pdb.isnull())
{
oddb:wgversion dd1 = pdb1->version();
oddb:wgversion dd2 = pdb->originalfileversion();
oddb:wgversion dd3 = pdb->originalfilesavedbyversion();
}
output:
dd1 = dd2 = dd3 = kdhl_1021
i have no idea why, can anybody help me? thanks.
version() is just current database version. it will be the same as originalfileversion() until you convert database to some other version.
originalfilesavedbyversion() is not handled by dd - it is read from the file as is. in new file it is set to zero.
vladimir


所有的时间均为北京时间。 现在的时间是 05:48 PM.