Access String Tokenizer

paulig2001

Registered User.
Local time
Today, 09:04
Joined
Apr 12, 2005
Messages
13
Is there any way, either through VBA, or queries or whatever to implement something similar to a Java String Tokenizer in Access?

What I want to do is change a big mad list of names, like "John O'Brien" to a list something like "johnobrien", for the purpose of accessing image files with names in that format, eg "johnobrien.jpg"
 
Code:
Public Function Tokenise(ByVal strName As String) As String
    strName = Replace(strName, " ", vbNullString)
    strName = Replace(strName, "'", vbNullsting)
    strName = StrConv(strName, vbLowerCase)
    Tokenise = strName
End Function
 
SJ McAbney said:
Code:
Public Function Tokenise(ByVal strName As String) As String
    strName = Replace(strName, " ", vbNullString)
    strName = Replace(strName, "'", vbNullsting)
    strName = StrConv(strName, vbLowerCase)
    Tokenise = strName
End Function
Cheers boss!
 

Users who are viewing this thread

Back
Top Bottom