'if second(now)<10 then c_second="0" & second(now) else c_second=minute(now) fileExt_a=split(szFilename,".") fileExt=lcase(fileExt_a(ubound(fileExt_a)))
SaveRandFileName=replace(replace(replace(now,":",""),"-","")," ","")&int(10*rnd)&"."&fileExt 'GenerateRandomFileName = year(now)&c_month&c_day&c_hour&c_minute&c_second&"_"&ranNum&"."&fileExt end function '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' function jaron_replacer(strContent,start_string,end_string,replace_string) 'CMS替换函数:源字符串,前部分,后部分,替换成的字符 '返回被替换后的字符串 jaron_replacer = replace(strContent,mid(strContent,instr(strContent,start_string),instr(strContent,end_string)+len(end_string)-1),replace_string) end function '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' function replaceplus(strContent,start_string,end_string,replace_string) '文档中,将所有开始,结束之间的所有字符删除 on error resume next MARKCOUNTS = ubound(split(strContent,start_string)) PRESTRING = strContent for i=0 to MARKCOUNTS STARTMARK=instr(1,PRESTRING,start_string,1) if STARTMARK=0 then exit for COMPMARK=instr(1,PRESTRING,end_string,1) + len(end_string) VerString=mid(PRESTRING,STARTMARK,COMPMARK - STARTMARK) PRESTRING = replace(PRESTRING,VerString,replace_string) next replaceplus = PRESTRING if err.number<>0 then err.Clear end function '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' %>
上一页 [1] [2] |
|