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

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

  [复制链接]

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

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

admin 楼主

2015-2-25 13:00:05

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

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

x

# N( S( |7 X* p: |/ e" V3 g' v% E1 o

1 k* ]9 R" v& Y% T, W7 EOnce you have fully tested your NXOpen API application, you should "sign" it
3 R) T4 e  l& H5 E; hbefore distributing it to your end users.  Even if your end users also have. R2 l& A) M( C5 r. o
access to the Author license which is required to load and run an NXOpen
  a+ {& m0 a" Q  z7 J* [$ Japplication, signing it has its benefits.
. `# \; O4 q4 W2 R! L
# l5 }6 T( P! ^: I7 E/ ~0 `: X    - Your application will load faster because NX will immediately recognize
( A! W3 U0 S, D# ^      that it has been signed.
9 i8 O4 b% z: E( g    - The syslog (Help-> Log File) will not be cluttered with the output from
9 `8 }4 G  p6 D  H      the multiple checks that NX will do to determine whether it can load) }! E/ W1 d- B- Z3 g
      and run the program.
, ]# p4 g, V; u0 H* u5 h
; k, D  r/ w# g1)  C/C++, C# or VB only (Java: Proceed directly to step 3)
  T4 g' i% x# f# _/ R: ?- W- ^! v* @/ \% r
    Add the NXSigningResource to your Visual Studio project
9 q% A0 T; T5 t" [8 X) s" M. z) D3 d
    In the Solution Explorer, select the Resource Files folder and& W6 m% W- R# R
        <RMB>Add-> Existing Item+ k+ R" E6 R& W3 k  h0 I; H
% z: V  ]" K( W
    C/C++:: G8 b/ Y+ e* i% T/ p# k: }: d. z
        Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.cpp0 _1 z: m+ |' u8 {4 V. h
    C# or VB .NET:, k) ?& R: n  }5 P, f( [/ \+ S& S
        Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.res
' i& o7 D8 n! H8 C& U        Select the newly added NXSigningResource.res and in set
5 ^- o& O5 @0 D* y4 M$ d3 ?  n            Properties-> Build Action = Embedded Resource# @' Y( z/ O6 l
5 c7 u* d( g. o' I( {0 `* Q
2)  Make sure the build configuration is set to Release then% M% }; C6 ~0 ?! \
    Build-> Rebuild Solution
% N- l6 q8 [. R1 H3 u: q0 a* [  S7 K+ k3 H
3)  Sign the executable from an NX Command Prompt window:- |, I, k5 u$ c  x$ m  R
        You probably already have one open because you started the Visual; ?! S9 X/ p1 P* H8 y( [
        Studio or Eclipse from it.  Otherwise:
* P# j) H& W* F6 T8 V            Start-> All Programs-> NX#-> NX Tools-> Command Prompt
+ H( }- H8 h; t) O: S8 ^* s+ K3 Y6 |% n$ r$ O, I. R
    Java:
# I9 ^' L- `" A' y0 O# l) g        signJar <path to your>.jar; P$ C% A  S- D4 Y

" J. K2 @: u) L1 N    C/C++:
* f/ \0 b/ m0 R1 W- O        NX8.5 and later:
/ I7 V  `9 ?. I+ w& ^: t0 x, |            signCpp <path to your>.dll or .exe
4 c9 ^- y% k0 w8 w3 F; r2 \- O; k9 N        NX8.0 and earlier:8 a3 ?9 e: n5 o& {/ x
            nxSign <path to your>.dll or .exe
9 J" U1 s5 B# n/ B* W
) X) ~, V, ~) q    C# or VB .NET:
2 g4 [/ D- |: O! M" f3 e8 i        NX8.5 and later:. R: n5 I/ G6 o. P
            signDotNet <path to your>.dll or .exe5 Y6 p7 K5 l: ?4 D$ E; `$ f
        NX8.0 and earlier:, g5 Z2 b& Q0 w( i- }
            signLibrary <path to your>.dll or .exe: E9 t: G+ Y0 X5 j) k1 R% i& D- n1 W
' L5 D4 Z. Z9 b( m
Note:  You do not need to use the path to the signing utilities because the
8 X8 P# U/ K) k! T- ~/ u' U) ]PATH of the NX Command Prompt shell already includes both the UGOpen and UGII
/ O" d  }9 ]; C$ w$ a/ G4 M  Pfolders.
4 b/ `, m' }; C+ c4 |* S3 _5 m7 Q& ]0 x* h* F# H& G
上海点团信息科技有限公司,承接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二次开发专题模块培训报名开始啦

    我知道了