If True do not display

B

Bill

I have a form which contains a sub form. In the sub form (CallDisplay) I
have it displayed in datasheet view and have a column with a check box. What
I need is if the check box is true (checked) then that entire line is not
displayed any longer. So I'm thinking something like:

Private Sub Closed_AfterUpdate()
If Me.Closed = True Then
Me.ID.Visible = False
Me.time.Visible = False
Me.incident.Visible = False
Else
Me.ID.Visible = True
Me.time.Visible = True
Me.incident.Visible = True
End If
End Sub

Problem is nothing happens. I think I need to use a filter with an update
expression.

Help please.... Thx
 
B

Beetle

Base the subform on a query that only returns records where the Yes/No
field is false. Something like;

Select* From tblSomeTable Where FieldX = False;"

Then in the After Update event of the checkbox control on the
subform, simply requery the recordset;

Private Sub Closed_AfterUpdate()

If Me.Closed = True Then Me.Requery

End Sub

_________

Sean Bailey
 
B

Bill

Im not following you on this one. The table storing the data is CallLog.
I'm also not good at query's. Where do I place your code?

Select* From CallLog Where Closed = False;"
 
B

Bill

Really need help getting this one. I don't think the query will work,
although I am not familiar with them enough to know for sure. This form is a
call log with a refresh every 10 seconds. It is constantly displayed to show
the active calls.

When the user closes a call they are to check the box (Closed) and then a
window pops up asking for the closed detail.

Once the box is checked, I need that call to come off the call display so
that only open calls show. Otherwise the display will become very cluttered.

Any ideas on how to accomplish this would be great.

Thank you all for your help,

Bill
 
J

John W. Vinson

Really need help getting this one. I don't think the query will work,
although I am not familiar with them enough to know for sure. This form is a
call log with a refresh every 10 seconds. It is constantly displayed to show
the active calls.

When the user closes a call they are to check the box (Closed) and then a
window pops up asking for the closed detail.

Once the box is checked, I need that call to come off the call display so
that only open calls show. Otherwise the display will become very cluttered.

Base the call log form on a Query with a criterion of

=False

on the Closed yes/no field.
 
B

Bill

You know its really embrassing when its that easy!!!! LOL

Thank you very much for your help!!!

Bill
 

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