Sabtu, 04 Oktober 2014

Re: Vedr: Vedr: [ExcelVBA] Preventing keyboard use before userform shows



I've lost track of what has been suggested, but the following seems to work for me Excel 2003)

Set your UserForm.Tag="NG"
Make sure that the TagIndex for your TextBox is not 0

In the TextBox_Change() sub, add this code:
    If Me.Tag = "NG" Then
        Me.tx1.Text = ""
        End If

In the TextBox_Enter() sub, add this code:
    Me.Tag = "OK"

Dave Gathmann


Posted by:
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (17)
Be sure to check out TechTrax Ezine for many, free Excel VBA articles! Go here: to enter the ezine, then search the ARCHIVES for EXCEL VBA.

Visit our ExcelVBA group home page for more info and support files:

More free tutorials and resources available at:




Tidak ada komentar:

Posting Komentar