the 'find & Replace" function doesn't work in ACCESS 2019 Pro

Anonymous
2025-02-24T10:24:21+00:00

The 'Find and Replace' option used for text search doesn't work in ACCESS 2019 Pro +.

Microsoft 365 and Office | Access | For business | Other

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Anonymous
    2025-02-24T12:06:07+00:00

    Where are you trying to perform a find & replace? (Form, Table, Query, VBA/VBE, ... ???)

    Did it work previously? If so, what has changed?

    Can you provided detailed reproduction steps for us to try and replicate the issue. Perhaps a screen recording showing the issue.

    Have you tried updating/rolling back your build?

    Have you tried performing an Office/Access repair?

    0 comments No comments
  2. Anonymous
    2025-02-24T15:24:24+00:00

    You might find the following function useful:

    Public Function MultiReplace(varInput, ParamArray varReplacements())
    
        ' call like this:
    

    ' MultiReplace("The cat sat on the mat","cat", "mouse", "mat", "house")

    ' to return this:

    ' The mouse sat on the house

        Const MESSAGETEXT = "Uneven number of replacements parameters."
    
        Dim n As Integer
    
        Dim varOutput As Variant
    
        Dim intParamsCount As Integer
    
        If Not IsNull(varInput) Then
    
            intParamsCount = UBound(varReplacements) + 1
    
            If intParamsCount Mod 2 = 0 Then
    
                varOutput = varInput
    
                For n = 0 To UBound(varReplacements) Step 2
    
                    varOutput = Replace(varOutput, varReplacements(n), varReplacements(n + 1))
    
                Next n
    
            Else
    
                MsgBox MESSAGETEXT, vbExclamation, "Invalid Operation"
    
            End If
    
        End If
    
        MultiReplace = varOutput
    
    End Function
    

    You'd call it in an UPDATE query to make multiple replacements in each row simultaneously.

    0 comments No comments
  3. Anonymous
    2025-02-24T15:25:40+00:00

    You might find the following function useful:

    Public Function MultiReplace(varInput, ParamArray varReplacements())
    
        ' call like this:
    

    ' MultiReplace("The cat sat on the mat", "cat", "mouse", "mat", "house")

    ' to return this:

    ' The mouse sat on the house

        Const MESSAGETEXT = "Uneven number of replacements parameters."
    
        Dim n As Integer
    
        Dim varOutput As Variant
    
        Dim intParamsCount As Integer
    
        If Not IsNull(varInput) Then
    
            intParamsCount = UBound(varReplacements) + 1
    
            If intParamsCount Mod 2 = 0 Then
    
                varOutput = varInput
    
                For n = 0 To UBound(varReplacements) Step 2
    
                    varOutput = Replace(varOutput, varReplacements(n), varReplacements(n + 1))
    
                Next n
    
            Else
    
                MsgBox MESSAGETEXT, vbExclamation, "Invalid Operation"
    
            End If
    
        End If
    
        MultiReplace = varOutput
    
    End Function
    

    You'd call it in an UPDATE query to make multiple replacements in each row simultaneously.

    0 comments No comments
  4. Anonymous
    2025-02-24T20:30:29+00:00

    Massive thanks, I’ll try it 🙏

    0 comments No comments