|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
UG NX二次开发:创建一个临时文件的函数uc4577
5 A. c Q1 _7 E5 h- x8 B- x非常ok的一个函数,特意放在这里,供大家使用,可以随机的创建一个临时的文件,如果代码里有每次不固定的字符串,可以使用这个函数哦!!8 Q2 M- R+ \6 t6 Q
. K2 z4 h8 l, P# t) _: V, N. FDefined in: uf_cfi.h6 A' V% H( w. l: y
; }0 a# @- t, q
. J& t% L3 F0 X$ }& d! OOverview' i5 l* v2 i* a3 P% Y& v4 d
# O. O, T! {: g/ rThe name returned is a unique name for a temporary file. The resultant
8 A) V" [8 x, O, F3 U) S% M/ ~filename is unique from other processes at the time. From a single
3 a( P2 J% J$ Z$ K! K7 Cprocess, filenames will begin duplicating after the first 1,679,615 calls
- c# s% _8 u+ Q; o( x9 k- e2 }to uc4577. Temporary files should be deleted when no longer needed by an . Y p! \; }- U5 k6 k9 }- m
application. If the files are not deleted, there is a chance that the same 5 U9 j4 b/ ` v" }3 q
name may come up again if the same user happens to get the same process id
" f6 u# Y. `; w0 j; {5 j3 hon a later date. " K. Z5 y m1 m
; H' a7 p2 E' y7 H1 i
The maximum number of characters which will be returned is 12.
* [0 k# W* K% @' ]& o- u+ Z3 a
5 o6 X8 B9 l2 j" b+ s0 _& b
5 W0 y7 z# V ~0 M0 ~& zEnvironment) A) _$ A; B" Y4 G& K
4 I4 t2 Z8 Q9 K) ?' |
Internal and External 6 u# J: u% a& j6 s: v: N# N% a2 ?" r' B
/ ~* q- {6 H) M% n' }( k v; o
+ _+ |' b; @7 y6 _Required License(s)& ~4 b/ O8 S( ^$ C2 U' Q$ Y, N7 o
2 {3 q x2 Z/ n4 S
gateway
0 H8 X! U0 E+ P' g0 T. X; k+ ^- e, u' X9 r6 i
* C! ?9 Q' n- A' J; ~3 Zint uc4577
: d) Y Q# D; Z4 f: |/ a. K0 P(3 _* i( G2 F/ F0 g6 J/ A$ @
char fname [ UF_MAX_UNIQUE_FILE_NAME_BUFSIZE ]
4 F0 B7 r1 G' N3 \! v4 m; B5 w' _- O* J
)" U" ^( q C8 e! V' J- I V
5 O# w2 k) V: z3 ]# E5 G% r: g9 q; [ T char | fname [ UF_MAX_UNIQUE_FILE_NAME_BUFSIZE ] | Output | Unique filename |
|
|