On Error Resume Next
cdlTest.CancelError = True
cdlTest.DialogTitle = "上传视频"
cdlTest.FileName = App.Path
cdlTest.DefaultExt = "MP4(.MP4)|*.MP4"
cdlTest.Filter = "MP4(.MP4)|*.MP4|mpg(.mpg)|*.mpg|3gp(.3gp)|*.3gp|所有文件|*.*"
cdlTest.ShowOpen
dim a as string,b as string,c as string
a=cdlTest.filename
if a<>"" then
b=iif(instrrev(a,".")>0,"." & right(a,len(a)-instrrev(a,".")),"") '获取该文件的扩展名
if trim(text1)<>"" then filecopy a,app.path & "\" & text1 & b '如果text1内文字合法则复制并改成需要的文件名
endif
[ 本帖最后由 lowxiong 于 2014-5-6 16:16 编辑 ]
cdlTest.CancelError = True
cdlTest.DialogTitle = "上传视频"
cdlTest.FileName = App.Path
cdlTest.DefaultExt = "MP4(.MP4)|*.MP4"
cdlTest.Filter = "MP4(.MP4)|*.MP4|mpg(.mpg)|*.mpg|3gp(.3gp)|*.3gp|所有文件|*.*"
cdlTest.ShowOpen
dim a as string,b as string,c as string
a=cdlTest.filename
if a<>"" then
b=iif(instrrev(a,".")>0,"." & right(a,len(a)-instrrev(a,".")),"") '获取该文件的扩展名
if trim(text1)<>"" then filecopy a,app.path & "\" & text1 & b '如果text1内文字合法则复制并改成需要的文件名
endif
[ 本帖最后由 lowxiong 于 2014-5-6 16:16 编辑 ]