this code extracts the filename from a filepath & name. for example, if i had C:\windows\desktop\me.html it would give me me.html. my question is, how do i use this code thought?
Public Function ExtractFileName(strPath As String) As String
' StrReverse is only working in VB6
strPath = StrReverse(strPath)
strPath = Left(strPath, InStr(strPath, "\" - 1)
ExtractFileName = StrReverse(strPath)
End Function
Public Function ExtractFileName(strPath As String) As String
' StrReverse is only working in VB6
strPath = StrReverse(strPath)
strPath = Left(strPath, InStr(strPath, "\" - 1)
ExtractFileName = StrReverse(strPath)
End Function