NX二次开发-NXOPEN工程图导出CAD图纸DxfdwgCreator *dxfdwgCreator1;
没有什么可以看的,NXOPEN直接录制一下导出CAD就可以了。
录制出来自己挑需要的代码拿过来改一下。
NX9+VS2012 #include <NXOpen/Part.hxx>
#include <NXOpen/PartCollection.hxx>
#include <NXOpen/Session.hxx>
#include <NXOpen/DxfdwgCreator.hxx>
#include <NXOpen/DexManager.hxx> DxfdwgCreator *dxfdwgCreator1;
dxfdwgCreator1 = theSession->DexManager()->CreateDxfdwgCreator(); dxfdwgCreator1->SetExportData(DxfdwgCreator::ExportDataOptionDrawing); dxfdwgCreator1->SetAutoCADRevision(DxfdwgCreator::AutoCADRevisionOptionsR2004); dxfdwgCreator1->SetViewEditMode(true); dxfdwgCreator1->SetFlattenAssembly(true); dxfdwgCreator1->SetExportScaleValue("1:1"); //dxfdwgCreator1->SetOutputFileType(DxfdwgCreator::OutputFileTypeOptionDxf);//导出DXF
dxfdwgCreator1->SetOutputFileType(DxfdwgCreator::OutputFileTypeOptionDwg);//导出DWG dxfdwgCreator1->SetOutputFile("D:\\test5.dwg"); dxfdwgCreator1->ObjectTypes()->SetCurves(true); dxfdwgCreator1->ObjectTypes()->SetAnnotations(true); dxfdwgCreator1->ObjectTypes()->SetStructures(true); dxfdwgCreator1->SetInputFile("D:\\test5.prt"); NXObject *nXObject1;
nXObject1 = dxfdwgCreator1->Commit(); dxfdwgCreator1->Destroy();
NX二次开发-NXOPEN工程图导出CAD图纸DxfdwgCreator *dxfdwgCreator1;的更多相关文章
- NX二次开发-NXOPEN自动切换到工程图模块
UFUN的API里是没有切换到工程图的函数的,NXOPEN里是有方法可以用的.不过应该是不支持NX9以下的版本. NX9的不能录制出来,在UI类里有方法 NX9+VS2012 #include < ...
- NX二次开发-将工程图上的每个视图导出PNG图片
大概思路是将每个视图导出PDF,在调另一个项目的EXE(PDF转PNG) //ExportDrawViewPng // Mandatory UF Includes #include <uf.h& ...
- NX二次开发-将工程图视图+尺寸的最大边界导出图片
/***************************************************************************** ** ** ExportPicture.c ...
- NX二次开发-NXOPEN导出STEP Step214Creator *step214Creator1;
没有什么可以看的,NXOPEN直接录制一下导出STEP就可以了.录制出来自己挑需要的代码拿过来改一下. NX9+VS2012 #include <NXOpen/Part.hxx> #inc ...
- NX二次开发-NXOPEN更改工程图视图名字baseView1->SetName("LSY");
NX9+VS2012 #include <uf.h> #include <uf_draw.h> #include <uf_obj.h> #include <u ...
- NX二次开发-NXOPEN设置工程图表格注释字体workPart->Fonts()->AddFont("chinesef_fs", NXOpen::FontCollection::TypeNx);
NX9+VS2012 #include <uf.h> #include <uf_tabnot.h> #include <NXOpen/Part.hxx> #incl ...
- NX二次开发-NXOPEN获取所有工程图和所有视图DrawingSheet,DrawingSheetCollection,DraftingView
NX11+VS2013 #include <NXOpen/Part.hxx> #include <NXOpen/PartCollection.hxx> #include < ...
- NX二次开发-NXOPEN将工程图转成PDF文件
NX9+VS2012 #include <uf.h> #include <uf_draw.h> #include <NXOpen/PrintPDFBuilder.hxx& ...
- NX二次开发-NXOPEN创建工程图表格Annotations::TableSectionBuilder *tableSectionBuilder1;
NX9+VS2012 #include <uf.h> #include <uf_tabnot.h> #include <NXOpen/Part.hxx> #incl ...
随机推荐
- jQuery冒泡事件阻止
JQuery 提供了两种方式来阻止事件冒泡. 方式一:event.stopPropagation(); $("#div1").mousedown(function(event){ ...
- vue2 核心概念
一.vue变量 所有的 vue变量 ,必须在data:中有注册(哪怕内容是空,相当于声明这个是变量,是vue变量而不是js变量).这里的变量也可以运算.(注意:所有的框架一定要注意js变量和框架的变量 ...
- (抓)ubuntu下安装mysql --- 我主要参考的文章
转:http://cycnet.blog.51cto.com/117809/812625 现在的软件越来越好安装,尤其是在ubuntu下安装软件,更是没有技巧,只需要在联网的情况下使用apt-get ...
- linux find相关 (持续更新中)
按名字查找 find . -name *.txt find . -name test* # . 指的是当前路径, 查找全局的话把. 换成/ 查找并删除多个文件 find -type f -name & ...
- python re.findall 使用
python re.findall 使用 import re #\w 匹配字母数字及下划线 print(re.findall('\w','hello alan _god !@^&#^$^!*& ...
- SSM框架整合思路
SSM框架整合思路 Spring在整合中起到的作用(面试时常问到) Spring管理持久层的mapper. Spring管理业务层的service,service可以调用mapper接口.Spring ...
- hexo next主题深度优化(一),加入pjax功能。
文章目录 背景: 进入正题 pjax初体验--instantclick 真正的pjax 第一步 第二步 第三步 第四步 专门基于hexo next主题的pjax(将丢失的js效果重现) 将下面讲到的提 ...
- git clone慢的解决办法
转自:http://www.kindemh.cn/ 转自Kindem的博客 问题 大家可能都遇到过从github使用git clone指令奇慢无比的问题,网上很多人说使用代理来加速git,但是这也不是 ...
- TLS/SSL 协议 - ServerKeyExchange、ServerHelloDone
ServerKeyExchange ServerKeyExchange消息的目的是携带密钥交换的额外数据.消息内容对于不同的协商算法套件都会存在差异.在某些场景中,服务器不需要发送任何内容,这意味着在 ...
- super_blocks没有导出
在模块中,通过查询super_blocks列表,来遍历系统中的所有super_block,但是出现与下面类似的错误: http://stackoverflow.com/q/5051111/941650 ...