结合FSO操作和Aspjpeg组件写的Class(4)


Filerename="目录下已存在与更改后的文件名称相同的文件,不允许覆盖"
Exit Function
Else
Call Filedelete(UpDir(OldName)&"\"&NewName)
End If
End If
Set FsoFile=fso.GetFile(OldName)
FsoFile.Name=NewName
Set FsoFile=Nothing
Filerename=True
End Function

Public Function FileRun()
If File_NewFolder_Path="" and File_NewName="" then
FileRun="此操作执行后并未对指定文件产生变动,系统自动中止"
Exit Function
ElseIf File_Path="" or Not(fso.FileExists(File_Path)) then
FileRun="要进行操作的文件不存在"
Exit Function
ElseIf Instr(File_AllowType,GetExtensionName(File_Path))=0 then
FileRun="要进行操作的文件被系统拒绝,允许的格式为: "&Replace(File_AllowType,"|"," ")
Exit Function
End If

If File_NewFolder_Path="" then
File_NewFolder_Path=UpDir(File_Path)
ElseIf Not(fso.FolderExists(File_NewFolder_Path)) then
FileRun="指定要移动到的目录不存在"
Exit Function
End If
If Right(File_NewFolder_Path,1)<>"\" then File_NewFolder_Path=File_NewFolder_Path&"\"
If File_NewName="" then
File_NewPath=File_NewFolder_Path&GetFileName(File_Path)
Else
File_NewPath=File_NewFolder_Path&File_NewName&"."&GetExtensionName(File_Path)
End If
If File_Path=File_NewPath then
FileRun="此操作执行后并未对指定文件产生变动,系统自动中止"
Exit Function
ElseIf UpDir(File_Path)<>UpDir(File_NewPath) then
If File_deleteIf=1 then
Call FileMove(File_Path,File_NewPath,File_CoverIf)
Else
Call FileCopy(File_Path,File_NewPath,File_CoverIf)
End If
FileRun=True
Else
'If File_deleteIf=1 then
Call Filerename(File_Path,GetPrefixName(File_NewPath),File_CoverIf)
'Else
' Call FileCopy(File_Path,File_NewPath,File_CoverIf)
'End If
FileRun=True
End If
End Function
End Class
%> 


《ASPJPEG综合操作CLASS》
>>>---------我想分页!--这么长的文章,在这里来个分页多好啊!哈哈----------<<<
《ASPJPEG综合操作CLASS》
基本上能实现ASPJPEG的所有功能
代码有详细注释,还不懂的请提出

有建议及更多功能提议的请提出

谢谢

 程序代码
<%
'ASPJPEG综合操作CLASS
'Authour: tony 05/09/05
Class AspJpeg
Dim AspJpeg_Obj,obj
Private Img_MathPath_From,Img_MathPath_To,Img_Reduce_Size,CoverIf
Private Img_Frame_Size,Img_Frame_Color,Img_Frame_Solid,Img_Frame_Width,Img_Frame_Height
Private Img_Font_Content,Img_Font_Family,Img_Font_Color,Img_Font_Quality,Img_Font_Size,Img_Font_Bold,Img_Font_X,Img_Font_Y

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:http://www.heiqu.com/3382.html