?
Solved

MS Access 2002 Forms applying a filter with command button allowing a field from that form with a wildcard

Posted on 2003-04-01
3
Medium Priority
?
185 Views
Last Modified: 2006-11-17
MS Access 2002 Forms - How do you:
Apply a filter with command button allowing a field from that form with a wildcard.  problem: Filter by Selection selects by exact field value.

assuming I'm in a record where field [last name]= "smith"
how can i structure command button that filters with a wildcard (Smith*) so I get all Smith, Smithson, Smith Jr., etc....

the command button would work on any record so if [last name] = "jones", it would work same way.
0
Comment
Question by:leuchte
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 5

Expert Comment

by:Mike77
ID: 8247312
try :

[last name] like "smith*"
0
 
LVL 5

Accepted Solution

by:
Mike77 earned 100 total points
ID: 8247328
in the after update event of the button use code like :

me.Filter = "[last name] like '" & YourCondition & "*'"
me.FilterOn = true
0
 
LVL 1

Expert Comment

by:DCCoolBreeze
ID: 8247395
If your form does not display the data by using the code above which is correct (remember the closing quotes that need to surround SMITH.  It is hard to see that in the note above) then add one more line me.requery
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access custom database properties are useful for storing miscellaneous bits of information in a format that persists through database closing and reopening.  This article shows how to create and use them.
AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question