current form filter

G

Guest

I have a pop-up form that contains 4 combo boxes. I place A command button on
the pop-up form to open another form which based upon the criteria selected
from the pop-up form. It works great. Now I place command button on the
active form to filter for null value of a certain control. It works, but
the form re-loads and displays every records that has null value for that
control. I would like to filter the form as current so I wouldn't have to
lose the criteria that was used to open the form in the first place.

I appreciate your kind response.
Thanks

I am using this code to filter the current form

Me.Filter = "[Action Taken] Is Null"
Me.FilterOn = True
 
P

Pieter Wijnen

How about:
If Len(Me.Filter)>0 Then
Me.Filter = Me.Filter & " And " & "[Action Taken] Is Null"
Else
Me.Filter = "[Action Taken] Is Null"
End if

HTH

Pieter
 
G

Guest

Thank you for your prompt response to my post. But it doesn't solve my
problem. When I click the cmdButton on the form I still get different
dialogue pop-ups asking for the criteria I've used to Open the form. If I
ignore them, it will filter the whole database instead of what have been
uploaded with the current form. I'd like to just filter the active form
without changing or enter new criteria.

Thanks again


Pieter Wijnen said:
How about:
If Len(Me.Filter)>0 Then
Me.Filter = Me.Filter & " And " & "[Action Taken] Is Null"
Else
Me.Filter = "[Action Taken] Is Null"
End if

HTH

Pieter

Pawdnos said:
I have a pop-up form that contains 4 combo boxes. I place A command button
on
the pop-up form to open another form which based upon the criteria
selected
from the pop-up form. It works great. Now I place command button on the
active form to filter for null value of a certain control. It works, but
the form re-loads and displays every records that has null value for that
control. I would like to filter the form as current so I wouldn't have to
lose the criteria that was used to open the form in the first place.

I appreciate your kind response.
Thanks

I am using this code to filter the current form

Me.Filter = "[Action Taken] Is Null"
Me.FilterOn = True
 

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