K
Kevin Bruce
In my work, I annually print several hundred contracts. Within the database,
new contracts are those for which a date of issue has not yet been recorded
in a textbox called 'txtContractedToPresenter'.
I have a form with one button that I want to have either print the new
contract or preview an existing one. The SQL statement for the report reads
the date in the text box and brings up the appropriate set of records. The
following statement in the 'ContractedToPresenter' field (a date field)
works just fine:
[Forms]![frmBookingPresenterContracts]![txtContractedToPresenter]
If I change this statement to Is Null, I get all those items not yet
contracted. That, too, is fine.
Where I am having trouble is in putting the two together so that the
Contract shows either those items corresponding to the contracted date
(ContractedToPresenter = txtContractedToPresenter) OR those yet to be
contracted (ContractedToPresenter = Null).
To my mind, the following statement should accomplish this, but it does not.
It works fine for those items that already have date, but returns an empty
record set for those that are still null.
IIf([Forms]![frmBookingPresenterContracts]![txtContractedToPresenter] Is Not
Null,[Forms]![frmBookingPresenterContracts]![txtContractedToPresenter],Is
Null)
Any suggestions?
Thanks.
_Kevin
new contracts are those for which a date of issue has not yet been recorded
in a textbox called 'txtContractedToPresenter'.
I have a form with one button that I want to have either print the new
contract or preview an existing one. The SQL statement for the report reads
the date in the text box and brings up the appropriate set of records. The
following statement in the 'ContractedToPresenter' field (a date field)
works just fine:
[Forms]![frmBookingPresenterContracts]![txtContractedToPresenter]
If I change this statement to Is Null, I get all those items not yet
contracted. That, too, is fine.
Where I am having trouble is in putting the two together so that the
Contract shows either those items corresponding to the contracted date
(ContractedToPresenter = txtContractedToPresenter) OR those yet to be
contracted (ContractedToPresenter = Null).
To my mind, the following statement should accomplish this, but it does not.
It works fine for those items that already have date, but returns an empty
record set for those that are still null.
IIf([Forms]![frmBookingPresenterContracts]![txtContractedToPresenter] Is Not
Null,[Forms]![frmBookingPresenterContracts]![txtContractedToPresenter],Is
Null)
Any suggestions?
Thanks.
_Kevin