Results 1 to 4 of 4
  1. #1
    oddsteven is offline Novice
    Windows XP Access 2007
    Join Date
    Oct 2009
    Posts
    5

    Macro tools wizard / making a button to open a form

    I've created a problem tracking database that is very simple. Within it is a form that tracks how many open problems are assigned to a particular technician.
    I also created a form that allows you to open up the entire entry for editing etc.


    The problem is that I want to create a button on the first form that will open the 2nd form with only the records assigned to that technician.
    In form design I click the "Button" button and pick Form Operations - Open Form, Next, Pick the form I want (frm_open_by_), click the "Open the form and find specific data to display.", Next, Highlight Tech Assigned on both sides and hit the <-> button and finish it off...

    See below for the code that the Macro gave me:

    (Action Open Form)
    Form Name: frm_open_by_
    View: Form
    Filter Name: (blank)
    Where Condition: "[Tech Assigned]=" & "'" & [Tech Assigned] & "'"
    Data Mode: (blank)
    Window Mode: Normal

    The macro works great, except it opens up ALL the records, not just the ones assigned to Jane Doe or John Doe or whomever. . .

    Thoughts, solutions? It's been giving me fits.

  2. #2
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    Is Tech Assigned a number or a text value? your code is assuming text and as text does not euwal number then no filter is applied.

    David

  3. #3
    oddsteven is offline Novice
    Windows XP Access 2007
    Join Date
    Oct 2009
    Posts
    5
    The Tech Assigned field is a text field not a number

  4. #4
    dcrake's Avatar
    dcrake is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Aug 2009
    Posts
    435
    Just before the macro runs type in the following

    MsgBox "[Tech Assigned]=" & "'" & [Tech Assigned] & "'"

    Does it give you what you would expect it to do?

    It could be you need to use the Me! operator. Not used 2007 yet.

    David

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

Similar Threads

  1. Making the launched form seperate from Access
    By MonsterMaxx in forum Access
    Replies: 1
    Last Post: 09-06-2009, 12:11 PM
  2. Access security - Password Recovery tools
    By sreedharreddy in forum Security
    Replies: 1
    Last Post: 04-01-2009, 08:14 AM
  3. Replies: 2
    Last Post: 03-13-2009, 08:35 AM
  4. Replies: 2
    Last Post: 11-17-2006, 01:07 PM
  5. Open a linked subform with a command button
    By flablueeyedblond in forum Forms
    Replies: 0
    Last Post: 11-18-2005, 01:18 PM

Tags for this Thread

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