PLM之家PLMHome-国产软件践行者

[二次开发源码] UG NX二次开发:创建一个临时文件的函数uc4577

[复制链接]

2016-3-28 16:55:02 2300 0

admin 发表于 2016-3-28 16:55:02 |阅读模式

admin 楼主

2016-3-28 16:55:02

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

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

x
UG NX二次开发:创建一个临时文件的函数uc4577
' W, e7 y# R- t非常ok的一个函数,特意放在这里,供大家使用,可以随机的创建一个临时的文件,如果代码里有每次不固定的字符串,可以使用这个函数哦!!
- f1 b% K4 ?1 n$ W$ N
2 j  D$ N) S. E( ]2 K% ~Defined in: uf_cfi.h
0 y  S4 w7 ]. \+ v
- L8 ~) A7 d! w$ k( c, Z* `* Z+ h0 {. A- j9 R5 U* t& ^
Overview1 U4 L2 u( h" d; l1 Q7 i
: Y+ n8 N+ ^  U4 ~
The name returned is a unique name for a temporary file.  The resultant
; ~! e0 j; H# \, mfilename is unique from other processes at the time.  From a single
4 n. r0 M( m2 p% cprocess, filenames will begin duplicating after the first 1,679,615 calls 4 D( B5 s, Q# g0 f
to uc4577.  Temporary files should be deleted when no longer needed by an 0 X, [, i. L  j# p" s$ ~  l
application.  If the files are not deleted, there is a chance that the same
/ k+ z  u9 D) O& m/ l1 kname may come up again if the same user happens to get the same process id
$ ^! E% R5 p7 oon a later date.
+ @6 t' ~& b7 L" ]+ ?! T  y. i  U  L  r$ T
The maximum number of characters which will be returned is 12.
3 B/ J; O# o* T% B5 P/ h; L' @" Y* c; N: o3 [! c( D
! q1 a) }9 o' X8 B* m% G
Environment* |+ i5 ~. K+ R7 a( ]; `
( Q4 {( z( R9 {* f7 y
Internal  and  External
) o4 U( G. X" u- v/ _, w8 _
: }, c  }4 h, S/ T  `0 {, d3 W- [
3 ?; G: P" d0 l2 f0 J% PRequired License(s), b( _, U; d8 W
* p: \  Y. U* q4 {
gateway$ [8 n) [' [) C0 j
, s7 e+ `* g, A- |
0 M. ^4 s/ n% {3 c% l) n
int uc4577
! A* [3 f4 ~; f2 G: l(
3 I! e6 V, S6 S2 [# I$ S0 Y8 P" Bchar fname [ UF_MAX_UNIQUE_FILE_NAME_BUFSIZE ]  
4 l( T5 N+ `$ D9 c, Z
# X+ `' l6 ?: g& @' S)
- O; S0 y$ G' s( W# C! a4 D" _
4 Y$ ]2 [( G7 D/ C
charfname [ UF_MAX_UNIQUE_FILE_NAME_BUFSIZE ] OutputUnique filename
上海点团信息科技有限公司,承接UG NX,CATIA,CREO,Solidworks 等CAx软件,Teamcenter,3D Experience等PLM软件,工业4.0数字化软件的实施\二次开发\培训相关业务,详情QQ 939801026 Tel 18301858168 网址 doTeam.tech
回复

使用道具 举报

发表回复

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

返回列表 本版积分规则

  • 发布新帖

  • 在线客服

  • 微信

  • 客户端

  • 返回顶部

  • x
    温馨提示

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

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

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

    我知道了