Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

3 Questions on - New Record/Parameter Entry/Data Carry Over. 2

Status
Not open for further replies.

jabrony76

Technical User
Apr 23, 2001
125
US

I posted this on the Access General Discussion board and received No responses in the last week and thought I might give this forum a try since you guys & gals have always been good to me...​

Hi all,
I have three questions and i figure i might as well ask them all in the same post to save time and energy for everyone! (Projects due monday, yikes) I'm using Access 97 and I don't know code too well, I do most of my access through queries and macros...

Q1-New Record
How can i set access up so that when a user tabs after the last field in a form they do NOT create a new record. Many people at my company are "sloppy tabbers" and are creating duplicate records and I want them to be able to see prior entries so "Data Entry-Yes" is not an option...

Q2-Paramater Entry Abbreviation
Is there a way to abbreviate a parameter when entering it into an "Enter Parameter Value" popup box. Not only are people "sloppy tabbers" but they are also lazy and don't want to enter their full name (Last, First) when they run a report for themselves. Can they enter "Doe, *" or something similar?

Q3-Data Carry Over to new record
How can i create a new record while having existing info carry over to the new form. For example, if someone is at a hospital for one service but then is transfered straight into the same facility with the same doctor but for a different service.
I would like to add a control that allows them to carry over the Hospital Name, Doctor, State, Age, etc.

I really appreciate if anyone can answer either or all of these questions! Thanks a bunch!
Andy
 
Hello Andy, I'll give it a shot.

1. Open your form in the design view. Open the property window for the form. On the "Other Tab" is a propety called Cycle. Set this to current record. Now when the user tabs and gets to the last control of the tab order, the curser will cycle back to the first control.

2. In your query that prompts the user for the information, instead of [Enter Value], use the Like operator and the wild card as shown below...

Like * & [Enter Value] & *

3. I'm positive this can be done several ways. I would choose to do it thru VBA. I would set up a check box on my form that would indicate if the user wanted to carry over the information. I would also have a button that added new records. This can be easily done thru the command button wizard. In the Click Event for this button just before the goto new record command I would put...

If CheckBoxName = True Then

Dim strHosp as String
Dim strDoctor as String

strHosp = HospFieldName
strDoctor = DoctorFieldName

End if

This would take temporarily store your values. Now After the goto new record command I would send those values back to thier fields.

If CheckBoxName = True Then

HospFieldName = strHosp
DoctorFieldName = strDoctor

End if


Hope this helps. B-)
ljprodev@yahoo.com
ProDev
MS Access Applications
 
Great tip Lonnie, your first one re the Cycle property. This has been bugging me and my users for ages. I will change all my forms immediately. Alex Middleton
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top