If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Reset Switchboard search control
I have an unbound text box on my switchboard into which users put criteria
which is then used to find the corresponding records. When the OnClick event of the command button fires, I want the text box to reset itself - deleting the previously entered value and making the field empty and ready for new input which again can be searched. I've tried using Me.Text2.Requery and Me.Text2.Undo but neither of these seem to work. I've even Me.Text2 = " " and while it does make the field blank, when the user then inputs data to search again, the system doesn't find a match. Thanks so much for any help! Pamela |
#2
|
|||
|
|||
Reset Switchboard search control
On Fri, 1 Jan 2010 13:50:01 -0800, Pamela
wrote: I have an unbound text box on my switchboard into which users put criteria which is then used to find the corresponding records. When the OnClick event of the command button fires, I want the text box to reset itself - deleting the previously entered value and making the field empty and ready for new input which again can be searched. I've tried using Me.Text2.Requery and Me.Text2.Undo but neither of these seem to work. I've even Me.Text2 = " " and while it does make the field blank, when the user then inputs data to search again, the system doesn't find a match. Thanks so much for any help! Pamela Me.Text2 = Null should work, if it's applied *after* the search has been run; obviously if you apply it too soon you'll simply erase the criterion entered by the user. Perhaps you could post your actual code, including the SQL view of the query. -- John W. Vinson [MVP] |
#3
|
|||
|
|||
Reset Switchboard search control
I decided to code the Switchboard to close and then reopen which resets the
unbound text box. Thanks! "Pamela" wrote: I have an unbound text box on my switchboard into which users put criteria which is then used to find the corresponding records. When the OnClick event of the command button fires, I want the text box to reset itself - deleting the previously entered value and making the field empty and ready for new input which again can be searched. I've tried using Me.Text2.Requery and Me.Text2.Undo but neither of these seem to work. I've even Me.Text2 = " " and while it does make the field blank, when the user then inputs data to search again, the system doesn't find a match. Thanks so much for any help! Pamela |
#4
|
|||
|
|||
Reset Switchboard search control
On Fri, 1 Jan 2010 14:05:01 -0800, Pamela
wrote: I decided to code the Switchboard to close and then reopen which resets the unbound text box. Thanks! Well, you can crack nuts with a hydraulic ram too... but a nutcracker is more appropriate. Me.textbox = Null will work fine. -- John W. Vinson [MVP] |
Thread Tools | |
Display Modes | |
|
|