I want to initiate a search macro by pressing the enter key after having entered the value to search
I don't want to use buttons or forms.
Is this possible??
Thanks
I want to initiate a search macro by pressing the enter key after having entered the value to search
I don't want to use buttons or forms.
Is this possible??
Thanks
So you want to run a search every time the enter button is pressed?
If you're happy with someone's help, click that little star at the bottom left of their post to give them Reps.
---Keep on Coding in the Free World---
No just when moving from the single variable cell. the rest of the sheet must operate as normal
So which cell or range of cells would you want this to apply to?
Two separate macro's one initiate from cell D3 and the other from G3
Those would be the only 2 cells where you would want a procedure to run after the user presses enter?
Yes. the rest of the sheet is only for the results.
Place the following code in the worksheet module that you want this to occurPlease Login or Register to view this content.
The code is doing something good I just need to adjust the macros to work. will post the solution once I have it.
Thanks
Please keep us informed.
Here is the working solution
Private Sub Worksheet_Change(ByVal Target As Range)
Dim FoundRng1 As Range
Application.EnableEvents = False
If Target.Address = "$D$3" Or Target.Address = "$G$3" Then
' Second macro is named Message1
Message1
End If
Application.EnableEvents = True
End Sub
and this is place on the VB sheet and not the module.
Within my macro I use an "IF" to rout between two.
Thanks
Hi evertjvr,
Your post does not comply with Rule 3 of our Forum RULES. Use code tags around code. Posting code without them makes your code hard to read and difficult to be copied for testing. Highlight your code and click the # at the top of your post window. For more information about these and other tags, found here
Here is the working solution
and this is place on the VB sheet and not the module.Please Login or Register to view this content.
Within my macro I use an "IF" to rout between two.
Thanks
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks