Dim fl As String = "d:\web\" & e.path
If filesys.FileExists(fl)
Dim idx As Integer = fl.LastIndexOf(".")
Dim ext As String = fl.SubString(idx)
Select Case ext
Case ".jpg",".gif",".png",".bmp",".wmf",".js",".css" ,".html",".htm",".zip",".rar"
e.WriteFile(fl)
Return '这里必须返回
End Select
End If
Select Case e.Path
Case "test.htm"
Dim wb As new WeUI
With wb.AddGallery("","gla1")
.AddImage("./images/001.jpg","./images/002.jpg","./images/003.jpg","./images/004.jpg")
End With
e.WriteString(wb.Build) '生成网页
End Select
http://www.foxtable.com/mobilehelp/scr/0087.htm
以上案例,如果路径中的图片不存在时,会提示出错
我想先判断图片名称是否在路径中,如果存在则显示图片,如果不存在则不显示
请问怎么写?