UG 編輯文本文字


 1 //textTag 文本tag
 2 NXOpen::Features::Text *text1(dynamic_cast<NXOpen::Features::Text *>(NXOpen::NXObjectManager::Get(textTag)));
 3 theSession->Parts()->Work()->Features()->SetEditWithRollbackFeature(text1);
 4 theSession->UpdateManager()->SetInterpartDelay(true);
 5 text1->MakeCurrentFeature();
 6 NXOpen::Features::TextBuilder *textBuilder1;
 7 textBuilder1 = theSession->Parts()->Work()->Features()->CreateTextBuilder(text1);
 8 string newTextValue = "123";//新文本值
 9 textBuilder1->SetTextString(newTextValue.c_str());
10 NXOpen::NXObject *nXObject1;
11 nXObject1 = textBuilder1->Commit();
12 textBuilder1->Destroy();

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM