Results 1 to 13 of 13
  1. #1
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7

    Post Access Forms

    Hi there,



    I am having some difficulties with my application. Firstlly i have the form that populates all faults logged regardless of the status, the source for my form is the query Q1. On the form i had an option to allow for filtering using fault reference number for which you must enter ref number and press the button. After you pressed the button the form must refresh to show only that fault. The problem i have is that when i press the button, my Q1 is modified to include the condition but the condition is save on the query. When i close the form and re-open it again, it doesn't default back to show all the faults.

    Can anyone help me out on this.

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,847
    There is a specific forum here for FORMS.

    As for your issue/question, you have not told us much about your database - its purpose, its structure....
    Q1 does not help the reader to understand your environment or your issue. Please post the SQL of the query (Q1).
    What is the purpose of Q1? Please describe the Form, its purpose, its controls....

    When you read your post, do you really think that others, unfamiliar with you, your database, your environment, your forms and your query could make any sense of it?

    For reference, pretend you are in a line up at McDonalds. you turn to the person behind you. That person doesn't know you; has no idea what a database is; and has minimal familiarity with computers. In the most simplistic terms and in plain English WHAT exactly would you tell that person to describe your problem?

  3. #3
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7
    thanks for your response,

    My query looks like:
    SELECT Issues.ID, Issues.[Fault Ref], Issues.Title, Issues.Caller, Issues.[Assigned To], Issues.[Opened By], Issues.[Opened Date], Issues.Status, Issues.Category, Issues.Priority, Issues.Description, Issues.[Resolved Date], Issues.[Related Issues].Value, Issues.Comments, Issues.Attachments, Issues.App
    FROM Issues;

    This query is my record source for my form. In other words, the form will display all records from the database. Since the records will be huge, i've added a textbox(txtSearch) and button (cmdSearch) on my form to apply a filter. When clicking that button i want the form to show only the record that matches the Reference number that i have entered on my textbox(txtSearch).

  4. #4
    msoffice.vidyarthi is offline Novice
    Windows 7 64bit Access 2000
    Join Date
    Nov 2012
    Posts
    24
    are you aware of the where criteria that you can utilize in the queries, where criteria will give you the right outpu

  5. #5
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,847

  6. #6
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7
    but i don't want it to filter on form load

  7. #7
    msoffice.vidyarthi is offline Novice
    Windows 7 64bit Access 2000
    Join Date
    Nov 2012
    Posts
    24
    It wont, attach the zipped db file which would help to review and make necessary changes

  8. #8
    msoffice.vidyarthi is offline Novice
    Windows 7 64bit Access 2000
    Join Date
    Nov 2012
    Posts
    24
    One turnaround is to put the table(instead of query) into the form and set the filter(coloumn=txtSearch.text), filteronload(false) properties

  9. #9
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7

    Hi

    Please find my application on the zip folder attached.
    Attached Files Attached Files

  10. #10
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7
    Quote Originally Posted by msoffice.vidyarthi View Post
    One turnaround is to put the table(instead of query) into the form and set the filter(coloumn=txtSearch.text), filteronload(false) properties
    Hi

    So how the command button will trigger the form to filter?

  11. #11
    msoffice.vidyarthi is offline Novice
    Windows 7 64bit Access 2000
    Join Date
    Nov 2012
    Posts
    24
    Just replace the code : Me.Filter = "Issues.[Fault Ref]=" & Chr(34) & [Ref] & Chr(34)

    by : Me.Filter = "ID=" & [Ref]

    this will work as per requirement, no other changes are required, reply with result

  12. #12
    Vistaz is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Oct 2012
    Posts
    7
    Quote Originally Posted by msoffice.vidyarthi View Post
    Just replace the code : Me.Filter = "Issues.[Fault Ref]=" & Chr(34) & [Ref] & Chr(34)

    by : Me.Filter = "ID=" & [Ref]

    this will work as per requirement, no other changes are required, reply with result
    Thanks it worked.

  13. #13
    msoffice.vidyarthi is offline Novice
    Windows 7 64bit Access 2000
    Join Date
    Nov 2012
    Posts
    24
    Quote Originally Posted by Vistaz View Post
    Thanks it worked.
    Would you click on the star below my post to add to my reputation

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 11-21-2012, 09:57 AM
  2. Access 2007 db forms not working in Access 2010
    By Butterfly13 in forum Access
    Replies: 2
    Last Post: 09-07-2012, 12:45 PM
  3. Replies: 1
    Last Post: 07-10-2011, 07:09 PM
  4. Access forms
    By shearnie in forum Forms
    Replies: 2
    Last Post: 03-08-2011, 01:12 AM
  5. Replies: 0
    Last Post: 01-19-2007, 07:58 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums