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

yang686526 2009-05-04 02:44 PM

【转帖】-setpathname90
 
->setpathname()
->setpathname()
i been using code below to update xrefpaths, this is working good.
try
{
odstring newxrefpath( userreferencepath );
pblock->upgradeopen();
pblock->setpathname( newxrefpath );
}
catch( oderror& e )
{
messagebox( null, svcs.geterrordescription( e.code() ), "", mb_ok );
}
but if i use exhostappservices::findfind() in my application(used for another part) the setpathname() will call findfile() with the existing ref path & filename. it can't be found so it throws a exception and does not update withthe new path name i want.
question: how can i make setpathname() work when myapplication also has findfile() ?
thank
cp
i have fixed the probalm by callingthe findfile() function in the parent class.
i wouldlike to returnthe same as the inbuilt findfile()
question: what does the parent class findfile() return sothat i can addthis to my virtual function so that the exception will not happen.
otherwise i have to have a boolean and decide whatto callin my findfile().
thx
cp


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