M
Mike
On a form I have created a button that I want to strip the " from all records
in a table. the following code will strip the " from the listed field in the
table:
Set rst = db.OpenRecordset("Mars_ext_pln_002_1000_rows")
Do While Not rst.EOF
strTemp = ""
strWrite = ""
strTemp = rst.Fields("ACT_ID")
x = 1
For x = 1 To Len(strTemp)
If Mid(strTemp, x, 1) <> Chr(34) Then
strWrite = strWrite + Mid(strTemp, x, 1)
End If
Next x
rst.Edit
rst.Fields("ACT_ID") = strWrite
rst.Update
rst.MoveNext
Loop
rst.Close
Does anyone know of away to do the same for the entire table without
repeating the code for each field in the table?
in a table. the following code will strip the " from the listed field in the
table:
Set rst = db.OpenRecordset("Mars_ext_pln_002_1000_rows")
Do While Not rst.EOF
strTemp = ""
strWrite = ""
strTemp = rst.Fields("ACT_ID")
x = 1
For x = 1 To Len(strTemp)
If Mid(strTemp, x, 1) <> Chr(34) Then
strWrite = strWrite + Mid(strTemp, x, 1)
End If
Next x
rst.Edit
rst.Fields("ACT_ID") = strWrite
rst.Update
rst.MoveNext
Loop
rst.Close
Does anyone know of away to do the same for the entire table without
repeating the code for each field in the table?