Results 1 to 4 of 4
  1. #1
    Join Date
    Mar 2004
    Posts
    64

    Question Unanswered: remove filter problem

    I created a database, on the switchboard the user will select a school, then it goes to a read only form that filters records only in that school. here in this form I would like to instruct the user how to filter the records by using the shortcut on the menu bar such as filter by selection or filter by form.

    My problem is when I select a field and click by selection, it works fine, but after this, if I want to remove the filter, I click the remove filter button, it then shows all the records for all the schools. I supposed it only still show the specific school I selected earlier. How can I achieve that?

    Thanks

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    I suppose you could trap the ApplyFilter event and set it to the original filter if the user is removing the filter entirely.
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Mar 2004
    Posts
    64

    Question remove filter

    I think if the user click remove filter, it will if the user is removethe filter entirely. How can I track that ?

    or how should I instruct the user to return to original filter?

    Thanls

  4. #4
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    In the ApplyFilter event, there is an "ApplyType" variable available to you. If the user is applying a filter, it will be -1, if they are removing all filters, it will be 0.

    Therefore, if it's 0, simply re-apply the original filter programmatically, the user will never know the difference.
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •