Sabtu, 29 Oktober 2011

RE: [MS_AccessPros] After subform is made visible, it is not displaying records linked to parent

 

Thank you Crystal. If I take your suggestion, what if a service task is part
of the estimate and part of the work order? Can I show that a service item
is two categories with your suggestion?

Thanks,

David

From: MS_Access_Professionals@yahoogroups.com
[mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Crystal
Sent: Saturday, October 29, 2011 3:14 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: Re: [MS_AccessPros] After subform is made visible, it is not
displaying records linked to parent

Hi David

Instead of having 3 yes/no fields, you should have a table to define the
work types, and a related table with each work type chosen. That way, there
is just ONE field to filter and search for. I imagine your subforms are
different depending on work type anyway.

to requery a subform:

me.subform_controlname.requery
or, which is technically more correct:
me.subform_controlname.form.requery

Warm Regards,
Crystal

* have an awesome day :)

________________________________
From: djsdaddy531 <drtolson@verizon.net <mailto:drtolson%40verizon.net> >
To: MS_Access_Professionals@yahoogroups.com
<mailto:MS_Access_Professionals%40yahoogroups.com>
Sent: Saturday, October 29, 2011 12:22 PM
Subject: [MS_AccessPros] After subform is made visible, it is not displaying
records linked to parent

Great Day, I have a form that permits the user to create a work order for
vehicle repair shop. There is a subform that allows the user to enter the
types of service needed: Oil Change, replace brake pads, tune up etc. Each
field can be associated with 1 or 3 categories:

1. Estimate (Is this service need part of the estimate);
2. Repair Order/Invoice (Is this service need part of the repair order);
3. Recommended (Was this service need something that the technician
discovered while (let's say) changing the oil, and makes the recommendation
to the owner. In this case, the tech may see that the oil pan gasket needs
to be replaced).

Each of these three categories are Yes/No data types. There could an
instance when an owner comes in and wants an oil change and a transmission
flush, but also hears a squeak and wants the technician to find out what it
is. The technician may find that the squeak is a bad wheel barring and the
cost may be $350. Although this will be part of the estimate, the owner may
decide to get the work performed at a later date, so replacing the wheel
barring does not become a part of the Repair Order/Invoice. Consequently, in
this case, category 1 and category 2 will be clicked for the Oil change and
transmission flush, but the replacement of the wheel barring will only have
category one (estimate) clicked.

So the form includes all items - estimates; repair orders, and service needs
that are recommended by the technician. What I am trying to do is place 3
command buttons on the main form that will filter the form to only display
records for one of the three categories, and a fourth button to show all
categories. I have placed three copies of the subform overlaying the first
subform (all categories), and here is the copy of the code for one of the
buttons (all of them are virtually the same)

Private Sub btnEstimateFilter_Click()
Me.frmScopeOfJobSub1.Visible = True
Me.frmScopeOfJobSub.Visible = False
Me.frmScopeOfJobSub2.Visible = False
Me.frmScopeOfJobSub3.Visible = False
Me.Refresh
Me.Requery
End Sub

All of the subforms are linked to the parent by JobID, but after the buttons
are clicked, the proper subform comes up, but I am not getting the records
linked to the JobID. It is basically an empty form.

Any suggestions on how I can get all of the subforms to show the records for
that particular JobID. Thanks in advance for your assistance.

r/David

------------------------------------

Yahoo! Groups Links

[Non-text portions of this message have been removed]

[Non-text portions of this message have been removed]

__._,_.___
Recent Activity:
MARKETPLACE

Stay on top of your group activity without leaving the page you're on - Get the Yahoo! Toolbar now.

.

__,_._,___

Tidak ada komentar:

Posting Komentar