+ Reply to Thread
Results 1 to 1 of 1

Autofilter & TextBoxes ... Left Over Character After Filter

Hybrid View

  1. #1
    Forum Expert Logit's Avatar
    Join Date
    12-23-2012
    Location
    North Carolina
    MS-Off Ver
    Excel 2019 Professional Plus - 2007 Enterprise
    Posts
    7,018

    Autofilter & TextBoxes ... Left Over Character After Filter

    .
    Two of the textboxes are designed to display a CHECK MARK when double-clicked. Also, if double-click again, the CHECK MARK is removed.

    Now to the issue :

    As the images below demonstrate, after the filter has been completed ... the textbox automatically erases the CHECK MARK (there is nothing in the autofilter macro that does this) and a
    QUESTION MARK is displayed in the textbox.

    WHY does the question mark show up ?

    I've looked at all the PROPERTY settings for the textbox and compared it with the other textboxes. I do not find anything different. And, again ... there is nothing in the macros
    that would instruct the insertion of the question mark.

    Thank you for reading and any assistance.


    #1 : Textbox double-clicked and the check mark is inserted.

    Search Entry.jpg



    #2 : Search result.


    Search Result.jpg



    #3 : After search is completed.

    Final.jpg




    This is the autofilter macro :


    Sub FilterAllCols2()
        Application.ScreenUpdating = False
        Dim LastRow As Long, x As Long
        Range("D:D").Columns.TextToColumns DataType:=xlDelimited, FieldInfo:=Array(1, 2)
        
        LastRow = Cells.Find("*", SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row
        For x = 1 To 4
            If ActiveSheet.OLEObjects("TextBox" & x).Object <> "" Then
                
                With Cells(2, 1).CurrentRegion
                    .AutoFilter x, "*" & ActiveSheet.OLEObjects("TextBox" & x).Object.Text & "*"
                End With
            End If
        Next x
        Application.ScreenUpdating = True
        Range("A2").Select
    End Sub


    Here is the double-click macro :


    Private Sub TextBox3_DblClick(ByVal Cancel As MSForms.ReturnBoolean)
            If TextBox3.Value = ChrW(&H2713) Then
                TextBox3.Value = ""
            Else
                TextBox3.Value = ChrW(&H2713)
            End If
    End Sub
    Last edited by Logit; 03-04-2020 at 12:08 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] left padding (with given character)
    By acolbrantNMBS in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 03-04-2019, 08:53 AM
  2. Select From right to left untill character is hit
    By lemunk in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-08-2016, 08:26 AM
  3. [SOLVED] Assistance with searching from the LEFT of a character
    By AceForSale in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 04-14-2016, 08:42 AM
  4. [SOLVED] How to use LEFT and RIGHT to delete last character
    By nicolaivinther in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 10-06-2014, 09:53 AM
  5. Replies: 3
    Last Post: 11-20-2012, 10:03 PM
  6. [SOLVED] Sum numbers left of a character from within a string
    By BarryTSL in forum Excel General
    Replies: 14
    Last Post: 04-17-2012, 01:11 PM
  7. Replies: 2
    Last Post: 08-19-2008, 07:18 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1