Posts by StrikeEagleCC

    What kind of data validation are you using? If users are still entering invalid data, it seems that perhaps the data validation could be set up differently to be more effective.

    What is the difference between the two columns? You mention that column B is "original full names". Like maiden names? Is column A nicknames?

    I have a workbook (workbook A) that contains a query to another workbook (workbook B) In workbook A, I have in the workbook module:

    Private Sub Workbook_BeforeClose(Cancel As Boolean)
    ThisWorkbook.Saved = True
    End Sub

    It works as expected, preventing the save dialog from appearing when the workbook is closed, unless the query is refreshed. If the query is refreshed, the dialog still appears when the workbook is closed. If I click "Cancel", and then close the workbook again, the dialog does not appear again. Stepping through the procedure, and using the immediate window, I can confirm that the workbook.saved property is indeed "True" when the procedure ends, and yet the dialog appears. What is causing the dialog to appear, and where can I go to stop it?

    I have noticed that when a form initializes, if a textbox control's value is changed in the initialization procedure and that control immediately receives focus, that control's AfterUpdate event fires. However, if debugging is used to step through the initialization and activation of the form, the event does not fire. Why not? This behavior is not limited to the initialization procedure, but more generally applies any time a procedure modifies another textbox's value, and that textbox then receives focus via tab/enter or .SetFocus. Again, when stepping through the procedure, this behavior is not observed. Why not? Is there any way I can prevent this behavior?

    To duplicate: Create a user form with two textboxes. UserForm1 code:

    Showing this form causes TextBox1_AfterUpdate() to run, unless a breakpoint is placed in the UserForm_Initialize() procedure. Changing the tab order, or uncommenting TextBox2.SetFocus causes TextBox2_AfterUpdate()