Use the Asc() function. Uppercase letters have ASCII values from 65 to
90. Lowercase letters have ASCII values from 97 to 122. To convert a
lowercase letter to an uppercase:
So, IsUpper("M") returns True, IsUpper("m") returns False. Not alphabetic
characters always return True of course. If a string of more than one
character is passed into the function it will act on the complete string,
i.e. it will return True only if all alphabetic characters are upper case.
You should be able to update the local and linked tables with some DAO which
loops throgh the Fields collection of each tabledef object and executes a
series of SQL statements. Be sure to back everything up first!
Dim dbs As DAO.Database, tdf As DAO.TableDef, fld As DAO.Field
Dim strSQL As String
Set dbs = CurrentDb
For Each tdf In dbs.TableDefs
If Left(tdf.Name, 4) <> "Msys" Then
For Each fld In tdf.Fields
strSQL = "UPDATE " & tdf.Name & _
" SET " & fld.Name & " = LCASE(" & _
fld.Name & ")"
On Error Resume Next
dbs.Execute strSQL
On Error GoTo 0
Next fld
End If
Next tdf
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.