Sub Image_Obj_1(Imagename,TempFilename,FileExt)
' 读取要处理的原文件
Dim Draw_X,Draw_Y,Logobox
Draw_X = 0
Draw_Y = 0
FileExt = Lcase(FileExt)
On Error Resume Next
ImageObj.Open Trim(Server.MapPath(Imagename))
If Err Then
err.Clear
Exit Sub
End If
If ImageObj.OriginalWidth
Exit Sub
Else
If FileExt<>"gif" and ImageObj.OriginalWidth > Draw_ImageWidth * 2 and Draw_Type >0 Then
Draw_X = DrawImage_X(ImageObj.OriginalWidth,Draw_ImageWidth,2)
Draw_Y = DrawImage_y(ImageObj.Originalheight,Draw_ImageHeight,2)
If Draw_Type=2 Then
Set Logobox = Server.CreateObject("Persits.Jpeg")
'*添加水印图片 添加时请关闭水印字体*
'//读取添加的图片
Logobox.Open Server.MapPath(Draw_Info)
Logobox.Width = Draw_ImageWidth '// 加入图片的原宽度
Logobox.Height = Draw_ImageHeight '// 加入图片的原高度
ImageObj.DrawImage Draw_X, Draw_Y, Logobox, Draw_Graph,Transition_Color,90 '// 加入图片的位置价坐标(添加水印图片)
'ImageObj.Sharpen 1, 130 '设置锐化值:锐化半径,深度
ImageObj.Quality=100'设置加水印后图片的质量
ImageObj.Save Server.MapPath(Imagename)
Set Logobox=Nothing
Else
'//关于修改字体及文字颜色的
ImageObj.Canvas.Font.Color = Draw_FontColor '// 文字的颜色
ImageObj.Canvas.Font.Family = Draw_FontFamily '// 文字的字体
ImageObj.Canvas.Font.Bold = Draw_FontBold
ImageObj.Canvas.Font.Size = Draw_FontSize '//字体大小
' Draw frame: black, 2-pixel width
ImageObj.Canvas.Print Draw_X, Draw_Y, Draw_Info '// 加入文字的位置坐标
ImageObj.Canvas.Pen.Color = &H000000 '// 边框的颜色
ImageObj.Canvas.Pen.Width = 1 '// 边框的粗细
ImageObj.Canvas.Brush.Solid = False '// 图片边框内是否填充颜色
'ImageObj.Canvas.Bar 0, 0, ImageObj.Width, ImageObj.Height '// 图片边框线的位置坐标
ImageObj.Quality=100 '设置加水印后图片的质量
ImageObj.Save Server.MapPath(Imagename)
End If
End If
If ImageObj.Width > ImageObj.height Then
ImageObj.Width = View_ImageWidth
ImageObj.Height = ViewImage_Height(ImageObj.OriginalWidth,ImageObj.Originalheight,View_ImageWidth,View_ImageHeight)
Else
ImageObj.Width = ViewImage_Width(ImageObj.OriginalWidth,ImageObj.Originalheight,View_ImageWidth,View_ImageHeight)
ImageObj.Height = View_ImageHeight
End If
ImageObj.Sharpen 1, 120
ImageObj.Save Server.MapPath(TempFilename) '// 生成预览文件
End If
End Sub
出现“系统找不到路径”!
ImageObj.Open Trim(Server.MapPath(Imagename))
说的是这句
????????????????????????????????????????????????????????shuo qing chu dian !!!!!!1