Printing Labels with a criteria in linked tables

G

Guest

I have 4 tables linked (Family, Member, DepartmentGroup, DateGroup) and I
mark kids present for sunday school in DateGroup (Dategroup.Dategroup stores
date, DateGroup.Present stores yes/no) The kids can come to either 9:30
service or 11:00 service or both. So I want to print security tags for them
with either 9:30 or 11:00 or both 9:30 and 11:00 if they are staying for
both. I have labels printing 'on click' in DateGroup.Present, and 9:30am amd
11:00am is stored in DepartmentGroup.Grouptime (as they can be part of many
different groups, at different times). I have a msgbox ask if they are
staying for both service, on 'no' it just prints 9:30 tag. I need it to check
current time and after 10:30am to print an 11:00am tag only and not ask the
question if you are stying for 2 services. However if the msgbox returns yes
(i'll stay for both services) I need it to mark 11:00am as 'yes' and to
select the security tag that is for 9:30 and 11:00am Can you please help, in
this length problem.
 
D

Douglas J Steele

When you're checking the response coming back from the message box, check
the time, and only print one label if it's after 10:30:

If MsgBox(.....) = vbYes Then
If Time() < #10:30:00# Then
' Print both
Else
' Print only one
End If
Else
' Print only one
End If

Alternatively, check the time BEFORE the message box, and only show the
message box if it's before 10:30.

If Time() < #10:30:00# Then
If MsgBox(.....) = vbYes Then
' Print both
Else
' Print only one
End If
Else
' Print only one
End If
 
G

Guest

Doug thanks for the speedy reply - I'll try what you said, however how do I
get VB to mark the person present at 11:00am (as they will not have the
oportunity to tag 11:00am present, becaue its a reponse to msgbox) How can I
get Vb to find current record, 11:00am group and make the groupdate.present
tag to yes? PR
 
D

Douglas J Steele

I think you're going to have to give a bit more information.

I had the impression that when you selected a record, you popped up a
message box asking whether this was for both services. If they answered Yes,
you printed out 2 tags. If they answered No, you printed out 1 tag.
 
G

Guest

Sorry Doug here goes: You are correct but I also need to mark the individual
kid as present for that group time, so the tables are linked, GroupDate
(stores todays date and present (yes/no), linked to the DepartmentGroup tabel
(here are stored all the differnet groups that peole can be part of ie.
11:00am grade 3 group, 9:30am grade 5 group), this tabel is linked to member
that is linked to family, So I can draw the details of each kid. Now when I
ask that question in msgbox I'm doing it 'on click' in the form that updates
the GroupDate table to mark present for a certain group ie, Joe Smith is
present for the 9:30am grade 6 group on today, now if he selecets to stay for
11:00am in the msgbox I need to still somehow mark 11:00am grade 6 group
today as present? Does this make sense I'm sorry I'm a hacker that needs
help! PR
 
D

Douglas J. Steele

I'm afraid I don't understand your explanation.

What does your existing code that presents the message box and prints the
tags look like?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top