PLM之家PLMHome-工业软件与AI结合践行者

[原创] NX二次开发签名的方法完整版本,详细步骤如下:

  [复制链接]

2017-4-21 08:17:55 8303 1

admin 发表于 2015-2-25 13:00:05 |阅读模式

admin 楼主

2015-2-25 13:00:05

请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!

您需要 登录 才可以下载或查看,没有账号?注册

x
. D7 {  u; P2 f
% @. R1 s! `: ^8 h7 b- M& O
/ \. t' H5 r  [" C
Once you have fully tested your NXOpen API application, you should "sign" it
$ l( o2 a( ?' f0 Zbefore distributing it to your end users.  Even if your end users also have
6 G1 ^' c) [" C& xaccess to the Author license which is required to load and run an NXOpen
9 ?9 O" I9 `% X3 gapplication, signing it has its benefits.  m+ ?0 i  q' w3 ]; Z  Q
+ [0 V( h! M) U1 E4 j
    - Your application will load faster because NX will immediately recognize# H7 R5 [. C& N0 P
      that it has been signed.
4 y/ g+ v1 [6 [+ v    - The syslog (Help-> Log File) will not be cluttered with the output from
9 }3 [& D/ M. Y; s9 r  |; L, j      the multiple checks that NX will do to determine whether it can load9 J2 y% I4 _; |
      and run the program.
4 n0 @0 p6 W1 `0 A; a  M# ?) x: O& _- m8 w% X. E* s
1)  C/C++, C# or VB only (Java: Proceed directly to step 3)( e# ?" b. j2 Y- h; h7 R

/ R' N, j6 j7 @& @" ]( t    Add the NXSigningResource to your Visual Studio project
/ Y8 i) ]' o+ y0 k  d  w
4 P& m. h/ z9 [    In the Solution Explorer, select the Resource Files folder and) V6 ?3 N" O  H- p) ^4 T
        <RMB>Add-> Existing Item: S. ?. r+ `. o/ x  [4 m
% K- p3 ]6 ?% v! @$ s; {! x% }$ @
    C/C++:4 O4 {( A7 n  x& x: w
        Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.cpp+ z+ A6 ^% n3 h: W3 {6 U
    C# or VB .NET:8 }. c: p+ K1 i9 T$ Z6 }
        Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.res
. U5 J( v4 `. _# t        Select the newly added NXSigningResource.res and in set. Z! P& o$ S, s' |( w: |
            Properties-> Build Action = Embedded Resource
- R9 [! J& }( ]4 r
/ y5 F6 `& Z: O2)  Make sure the build configuration is set to Release then
* E; P: C' |2 v- j3 o( m; y7 {    Build-> Rebuild Solution( W' K/ u$ Y. O" j

/ t/ Z6 M1 R# w$ Z3)  Sign the executable from an NX Command Prompt window:+ p& j% D5 J" C
        You probably already have one open because you started the Visual
1 ~0 l, L  t8 q8 ~" s/ F1 z8 I        Studio or Eclipse from it.  Otherwise:; q: h! W; f, r. w
            Start-> All Programs-> NX#-> NX Tools-> Command Prompt
3 e" k- V* w" y+ Y) L' y
+ D! [* k- k  ^7 E1 D2 z    Java:
- d% c7 Q- V$ D, |        signJar <path to your>.jar, w* j, Q+ X1 ?- @0 `

, z- f0 g: Q0 Y9 Z    C/C++:+ f/ Z+ |1 M9 d" v8 O5 U; ~
        NX8.5 and later:
( m* L) Z9 c: i9 ]: A4 F            signCpp <path to your>.dll or .exe- Q% @* H  o1 v
        NX8.0 and earlier:
  b. Q8 r. f1 u+ O# D# t1 F+ A            nxSign <path to your>.dll or .exe
$ S7 G, Q( ]. }. K
9 R6 g% k( B; V$ y/ s: i% p    C# or VB .NET:; z8 m4 z# h& [- X" ~
        NX8.5 and later:% C5 v. Z6 \3 L) u+ o' d6 f1 H
            signDotNet <path to your>.dll or .exe
+ d( ^6 S% k3 w6 i! X& E% z! R& M        NX8.0 and earlier:6 z4 \0 D: d- o
            signLibrary <path to your>.dll or .exe+ S  E, I8 l- M; o- I2 j
' P5 D- i! {) Y4 {9 A$ l: B* G1 q
Note:  You do not need to use the path to the signing utilities because the) Y! v& V% g# g7 U
PATH of the NX Command Prompt shell already includes both the UGOpen and UGII8 A- g/ T& [- o$ V
folders.; W: r. F" s  c" ?

8 a+ ?3 x( e. ?1 u$ L
上海点团信息科技有限公司,承接UG NX,CATIA,CREO,Solidworks 等CAx软件,Teamcenter,3D Experience等PLM软件,工业4.0数字化软件的实施\二次开发\培训相关业务,详情QQ 939801026 Tel 18301858168 网址 doTeam.tech
回复

使用道具 举报

全部回复1

yejihu 发表于 2017-4-21 08:17:55

yejihu 沙发

2017-4-21 08:17:55

非常感谢您的分享和宽大的胸怀!
上海点团信息科技有限公司,承接UG NX,CATIA,CREO,Solidworks 等CAx软件,Teamcenter,3D Experience等PLM软件,工业4.0数字化软件的实施\二次开发\培训相关业务,详情QQ 939801026 Tel 18301858168 网址 www.diantuankj.com/ doTeam.tech
回复 支持 反对

使用道具 举报

发表回复

您需要登录后才可以回帖 登录 | 注册

返回列表 本版积分规则

  • 发布新帖

  • 在线客服

  • 微信

  • 客户端

  • 返回顶部

  • x
    温馨提示

    本网站(plmhome.com)为PLM之家工业软件学习官网站

    展示的视频材料全部免费,需要高清和特殊技术支持请联系 QQ: 939801026

    PLM之家NX CAM二次开发专题模块培训报名开始啦

    我知道了