本片源码例子非本人所创,不过是转换了开发语言版本,此例非常具有学习效果,原文请查看
https://blog.youkuaiyun.com/lu1287580078/article/details/82916477?from=timeline Caesar卢尚宇优快云
class FD_CreateTrace
{
private NXOpen.Session theSession = null;
private NXOpen.UF.UFSession theUfSession = null;
private NXOpen.Part workPart = null;
private System.Windows.Forms.ProgressBar progressBar = null;
public FD_CreateTrace()
{
theSession = Session.GetSession();
theUfSession = UFSession.GetUFSession();
workPart = theSession.Parts.Work;
Form1 f1 = new Form1();
progressBar = f1.progressBar;
}
[Dll