几何尺寸与公差论坛------致力于产品几何量公差标准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)
-   -   【转帖】problem linking (http://www.dimcax.com/hust/showthread.php?t=18045)

yang686526 2009-05-06 10:51 PM

【转帖】problem linking
 
problem linking
problem linking
i have a link error with those functions in dbsymutl.h:
code:
const oddbobjectid& textstylestandardid(oddbdatabase* pdb);
const oddbobjectid& dimstylestandardid(oddbdatabase* pdb);
const oddbobjectid mlinestylestandardid(oddbdatabase* pdb);
the link error (unresolved external symbol) appears only in dll application (odamfcappdll).
i think that you forgot toolkit_export...
those functions are very usefull, could you do something for me, please ??
you are right. toolkit_export is missing. we'll fix it in next release/update. for now you can insert into your code:
code:
oddbobjectid mlinestylestandardid(oddbdatabase* pdb)
{
oddbdictionaryptr pdic = pdb->getmlstyledictionaryid().safeopenobject();
return pdic->getat(oddbsymutil::mlinestylestandardname());
}
oddbobjectid oddbsymutil::textstylestandardid(oddbdatabase* pdb)
{
oddbtextstyletableptr ptbl = pdb->gettextstyletableid().openobject();
return ptbl->getat(oddbsymutil::textstylestandardname());
}
oddbobjectid oddbsymutil::dimstylestandardid(oddbdatabase* pdb)
{
oddbdimstyletableptr ptbl = pdb->getdimstyletableid().openobject();
return ptbl->getat(oddbsymutil::dimstylestandardname(pdb->getmeasurement()));
}
sergey slezkin
thanks sergey !
in 1.11.1 we could do use copyfrom between two objects of different database,now we have an exception (wrongdatabase).
is there an other for copying two objects ?
copyfrom() should not be used for objects in different databases. else an object residing in one database will reference objects from another database.
oddbdatabase::wblockcloneobjects() will copy a set of objects to another database and take care about references.
sergey slezkin


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