NXOpen C++ CAM二次开发: 获取所有加工NC程序的时长
NXOpen C++ CAM二次开发: 获取所有加工NC程序的时长
void MyClass::do_it()
{
CAM::CAMSetup *camSetup = displayPart->CAMSetup();
CAM::OperationCollection *operColl = camSetup->CAMOperationCollection();
CAM::OperationCollection::iterator it = operColl->begin();
while( it != operColl->end() )
{
CAM::Operation *oper = (CAM::Operation*)(*it);
ostringstream out;
out << oper->Name().GetText() << endl;
out << " Toolpath Length: " << oper->GetToolpathLength() << endl;
out << " Toolpath Time: " << oper->GetToolpathTime() << endl;
out << " Toolpath Cutting Length: " << oper->GetToolpathCuttingLength() << endl;
out << " Toolpath Cutting Time: " << oper->GetToolpathCuttingTime() << endl;
print(out.str().c_str());
it++;
}
}
页:
[1]