trim只能去掉单字符
Dim fl As String = ProjectPath & "ABC.xls"
fl = fl.Trimend("s","l", "x", ".") & ".jpg"
msgbox(fl)