|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
2 m3 C6 f. `/ w" w9 M, ~- B/ l4 L
/ {7 C) W7 Z# `) `# M8 y" Z9 @4 B: D4 ^. h3 O/ L
Once you have fully tested your NXOpen API application, you should "sign" it0 x$ b3 |" V7 G# F+ Z9 W1 w
before distributing it to your end users. Even if your end users also have
3 i$ B6 g# g" J, g/ o' B9 [access to the Author license which is required to load and run an NXOpen1 w2 V0 T* Q8 U' V; r
application, signing it has its benefits." u- l( J1 z8 ~. a$ I: R
B7 K" y/ g2 ]# Q% H
- Your application will load faster because NX will immediately recognize( B. C6 B* _8 j# l; y; k* ~1 |$ A
that it has been signed.
' _; r+ l' Z* Y - The syslog (Help-> Log File) will not be cluttered with the output from
, k' ?, G; E- N; M the multiple checks that NX will do to determine whether it can load
1 b: ~ f2 o7 v8 @$ d6 b& P and run the program.3 z+ h& I3 ?1 F
/ m, e0 {5 i& q. r4 H) E- \
1) C/C++, C# or VB only (Java: Proceed directly to step 3)# M0 F6 [) ?5 x y+ h
: k# }/ K/ m/ D1 b. t8 F
Add the NXSigningResource to your Visual Studio project
3 G: {/ L$ Q; o' @4 Z9 ?
) w7 z+ K* R! I, d In the Solution Explorer, select the Resource Files folder and9 U/ `. d) r6 I4 I& C$ v C
<RMB>Add-> Existing Item
, A3 z7 U7 ]/ e" x- S% u& _$ O" q. r
C/C++:+ d* f% \! g& v0 g; n% |, d
Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.cpp$ V. ~1 h7 o7 s: T8 `" k" O
C# or VB .NET:5 i8 o+ P0 j4 c1 B. Q8 _3 s
Browse and select %UGII_BASE_DIR%\UGOPEN\NXSigningResource.res- z+ Y/ w# S% B3 ~1 ?2 r
Select the newly added NXSigningResource.res and in set
! o+ d- x. ?( J8 i6 T8 X Properties-> Build Action = Embedded Resource$ N6 T% r1 Q' p9 o, G* z
9 \; f$ K+ I& W# z: n2) Make sure the build configuration is set to Release then, Q7 Y. v9 O3 A$ _0 A- k+ _
Build-> Rebuild Solution
: ?+ o0 _& o3 T* I2 ^' t- d3 V
+ q, C, B3 {4 Q9 H6 ?# \- u3) Sign the executable from an NX Command Prompt window: M- @) g/ l* v; T- J! q1 ^& |' c
You probably already have one open because you started the Visual& B8 q3 q" T3 ^$ n
Studio or Eclipse from it. Otherwise:
5 D! ? M: q$ D1 m. u9 f/ t' n Start-> All Programs-> NX#-> NX Tools-> Command Prompt
* x' b, J _5 o" J9 x. I
8 Q) O' z- Y: ~: O _( u% \ Java:
! Z& b7 O2 _4 o signJar <path to your>.jar
! L2 `% G: s0 |6 u1 a# p: C$ l( K T: k. w+ Y) G+ `
C/C++:% `7 |) \ o) n- F
NX8.5 and later:
: {7 }& p% G: C$ C4 w8 y: S* O signCpp <path to your>.dll or .exe: P. I& ~; Z0 a5 o" j
NX8.0 and earlier:
' Y3 D. r. E$ T# M4 L) i nxSign <path to your>.dll or .exe
g: q3 k( k& @2 q% Y0 v
( @: [# R8 Q `. t6 t1 `3 z7 ]; H C# or VB .NET:
6 i9 \" ]! s5 } NX8.5 and later:
: z, b) |2 C: l6 a' N7 y signDotNet <path to your>.dll or .exe
# l2 X# w# _( W NX8.0 and earlier:
4 |# ]5 v( A8 J( o2 T* ^ signLibrary <path to your>.dll or .exe
$ X) ]' B ^& i0 K
9 _0 ^" m( ]0 }9 d+ M |5 B3 j1 e( z* iNote: You do not need to use the path to the signing utilities because the
, r+ n- _: V' qPATH of the NX Command Prompt shell already includes both the UGOpen and UGII5 x. [; q4 l5 c9 M, }" [' k
folders.- V4 P* K; N3 P, `. v
) B- B* h. L& F- X! K |
|