Microsoft Access Forums

Go Back   Microsoft Access Forums > Access Forums > Forms

Reply
 
LinkBack Thread Tools Display Modes
  #1  
Old 10-15-2009, 01:25 PM
oddsteven oddsteven is offline Windows XP Access 2007 (version 12.0)
Novice
 
Join Date: Oct 2009
Posts: 5
oddsteven is on a distinguished road
Default 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.
Reply With Quote
  #2  
Old 10-16-2009, 02:28 AM
dcrake's Avatar
dcrake dcrake is offline Windows XP Access 2003 (version 11.0)
Expert
 
Join Date: Aug 2009
Posts: 438
Blog Entries: 1
dcrake is on a distinguished road
Default

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
__________________
www.xcraftlimited.co.uk The Home of Simple Software Solutions.
Reply With Quote
  #3  
Old 10-16-2009, 05:46 AM
oddsteven oddsteven is offline Windows XP Access 2007 (version 12.0)
Novice
 
Join Date: Oct 2009
Posts: 5
oddsteven is on a distinguished road
Default

The Tech Assigned field is a text field not a number
Reply With Quote
  #4  
Old 10-16-2009, 05:54 AM
dcrake's Avatar
dcrake dcrake is offline Windows XP Access 2003 (version 11.0)
Expert
 
Join Date: Aug 2009
Posts: 438
Blog Entries: 1
dcrake is on a distinguished road
Default

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
__________________
www.xcraftlimited.co.uk The Home of Simple Software Solutions.
Reply With Quote
Reply

Bookmarks

Tags
buttons, forms, macros, wizards

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Making the launched form seperate from Access MonsterMaxx Access 1 09-06-2009 10:11 AM
Access security - Password Recovery tools sreedharreddy Security 1 04-01-2009 06:14 AM
making a check box disappear from a form when another box is selected dinarocks74 Access 2 03-13-2009 06:35 AM
making a form with checkboxes for answer to questions kfoyil Forms 2 11-17-2006 10:07 AM
Open a linked subform with a command button flablueeyedblond Forms 0 11-18-2005 10:18 AM


All times are GMT -8. The time now is 08:25 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.